getICollections
Getting all collections.
Description
It returns a Promise that resolves to an ICollectionEntity object.
IntegrationCollections.getICollections(
langCode,
userQuery
);
Parameters schema
Schema
langCode: string
Language code. Default: "en_US"
example: "en_US"
userQuery: object
Optional set query parameters
example:
{
"limit": 0,
"offset": 30,
"entityType": "orders",
"entityId": 1
}
Examples
Minimal example
const result = await IntegrationCollections.getICollections();
Example with attributes
const userQuery = '';
const result = await IntegrationCollections.getICollections('en_US', userQuery);
Example response
[
{
"id": 1,
"identifier": "test_collection",
"formId": 2,
"localizeInfos": {
"title": "test_collection"
},
"attributeSetId": null,
"selectedAttributeMarkers": null
}
]
Response schema
Schema: ICollectionEntity[]
id: number
Object identifier.
example: 1
identifier: string | null
Text identifier for record field.
example: "collection1"
formId: number | null
Identifier for the form used by the order storage.
example: 1234
localizeInfos: ILocalizeInfo
Localized information about the collection.
example:
{
"title": "Admins text"
}
attributeSetId: string | null
Identifier of the set of attributes used by the form attached to the collection.
example: "attributeSet1" or null if not applicable
selectedAttributeMarkers: string | null
Text identifiers of form object attributes for display in the data table.
example: "collection_marker"