Last Updated on : 2024-06-14 18:12:24download
manifest.json
is the provisioning profile of a microapp. Located in the root directory of the project, this file is used to describe the basic metadata of the current microapp.
The following table lists the microapp metadata.
Parameter | Type | Description | Required | Multilingual support |
---|---|---|---|---|
name | string |
The name of the specified microapp. It is used as the default menu name. | Yes | Yes |
type | string |
The file type and version. The current version is micro-apps/v1.1 . |
Yes | No |
appName | string |
The name of the specified microapp. It is unique to each developer account. | Yes | No |
annotations | Annotations {} |
The annotations. Provide remarks and ad hoc feature support based on conventions. | Yes | - |
appEngine | string |
The engine to run the specified microapp. Valid value: MICRO-FRONTEND . |
Yes | - |
description | string |
A simple description that supports multilingual settings. | No | Yes |
defaultMenuIcon | Icon {} |
The icon object. | No | - |
privileges | array[] |
The list of permissions. | No | - |
apis | Api [] |
The list of all dependent APIs for the specified microapp. | No | - |
supportedPlatform | string [ Enum ] |
The supported platform.
DESKTOP or MOBILE . |
No | - |
universalId | string |
The globally unique ID of a microapp, which is used for microapp navigation. The ID cannot be changed after it is generated. | No | - |
dependencies | string [] |
The list of microapps on which this microapp depends. If the current microapp has dependencies on other microapps, we recommend that you add the universalID of the depended microapps. Necessary prompts are added to avoid circular dependencies. |
No | - |
entries | Entries [] |
The entry to an application. Users can access the microapp through the exposed entry path. A microapp can have one or more entries. | No | - |
The custom extension field to record the remarks for the microapp. This custom field supports multilingual settings.
The following table describes the structure of the annotations
object.
Parameter | Type | Description | Required |
---|---|---|---|
sdf.cli:microFramework | Enum |
Specifies the technical type of template used to generate the current microapp. The enumeration values include:
|
Yes |
sdf.feat:colorTheme | boolean |
Specifies whether the current microapp needs to enable theme color configuration. | Yes |
sdf.feat:i18n | Enum |
When the microapp is launched, this key is used to determine whether to read the multilingual settings under the _locals folder to describe the microapp in a multilingual environment. Valid value: DYNAMIC , or this field can be left empty. |
No |
icon
indicates the icon of the specified microapp displayed on the Tuya Developer Platform.
The following table describes the structure of the DefaultMenuIcon
object.
Parameter | Type | Description | Required |
---|---|---|---|
type | Enum |
The icon type of the specified microapp. Valid value: URL . |
Yes |
name | string |
The icon URL of the specified microapp. If this field is left empty, the default icon is used.
|
No |
The following table describes the structure of the entries
object.
Parameter | Type | Description | Required | Multilingual support |
---|---|---|---|---|
type | Enum |
The type of the specified entry. Valid value: Menu . |
Yes | No |
name | string |
The name of the specified entry. Currently, only a menu is used as an entry, so this field is deemed as the menu name. | No | Yes |
code | Enum |
The ID of the specified entry. It is unique in a microapp. | Yes | No |
path | Enum |
The path to access the specified microapp. | Yes | No |
appIcon | AppIcon {} |
The icon of the specified entry. | No | No |
The following table describes the structure of the appIcon
object.
Parameter | Type | Description | Required |
---|---|---|---|
type | Enum |
The type of the specified entry. Valid value: CDN . |
Yes |
url | string |
The resource address of the specified icon . |
No |
size | Enum |
The icon size, which is 40 × 40 pixels. A 2x or 3x image is recommended. | Yes |
The following table describes the structure of the privileges
object.
Parameter | Type | Description | Required | Multilingual support |
---|---|---|---|---|
name | string |
The display name of the specified permission. | Yes | Yes |
code | string |
The code of the specified permission. The code is unique to each microapp and cannot be changed after defined. If the code is changed, the previously configured permission information will be lost, and you need to reconfigure the permission. | Yes | No |
The following table describes the structure of the apis
object.
Parameter | Type | Description | Required |
---|---|---|---|
namespace | Enum |
The type of the specified entry. Valid value: CDN . |
Yes |
method | Enum |
The method by which the request is made. Valid values: get , GET , post , POST , put , PUT , delete , and DELETE . |
Yes |
path | Enum |
The target path of the specified request. | Yes |
privilegeCode | Enum |
The available permission. You can get the corresponding permission code from the privileges object and fill it in. If this field is left empty, the permission is not restricted by default. That is, no permission verification is required before you make requests. |
No |
Is this page helpful?
YesFeedbackIs this page helpful?
YesFeedback