Loja
ecommercenamespaceCatálogo, produtos e resgate de itens.
5métodos
ecommercenamespaceEsta página é gerada automaticamente pelo
@luckymaker/sdk-generator. Não edite manualmente.
getItem
Seção intitulada “getItem”GET
/ecommerce/items/:idAssinatura:
getItem(id: string, settings?: SdkSettings): Promise<GetItemResponse>Parâmetros de rota
Seção intitulada “Parâmetros de rota”| Nome | Tipo |
|---|---|
id |
string |
type GetItemParams = { "id": string; };type GetItemResponse = unknown;Exemplo
Seção intitulada “Exemplo”const response = await sdk.ecommerce.getItem("string");Testar esta função no playground
listBrands
Seção intitulada “listBrands”GET
/ecommerce/brandsAssinatura:
listBrands(query?: ListBrandsQuery, settings?: SdkSettings): Promise<ListBrandsResponse>| Nome | Tipo | Obrigatório |
|---|---|---|
page |
number |
não |
ids |
string |
não |
slugs |
string |
não |
q |
string |
não |
type ListBrandsQuery = { "page"?: number; "ids"?: string; "slugs"?: string; "q"?: string; };type ListBrandsResponse = unknown;Exemplo
Seção intitulada “Exemplo”const response = await sdk.ecommerce.listBrands();Testar esta função no playground
listCategories
Seção intitulada “listCategories”GET
/ecommerce/categoriesAssinatura:
listCategories(settings?: SdkSettings): Promise<ListCategoriesResponse>type ListCategoriesResponse = unknown;Exemplo
Seção intitulada “Exemplo”const response = await sdk.ecommerce.listCategories();Testar esta função no playground
listItems
Seção intitulada “listItems”GET
/ecommerce/itemsAssinatura:
listItems(query?: ListItemsQuery, settings?: SdkSettings): Promise<ListItemsResponse>| Nome | Tipo | Obrigatório |
|---|---|---|
highlighted |
boolean |
não |
related_to |
string | number |
não |
category |
string | number |
não |
brand |
string |
não |
q |
string |
não |
limit |
number |
não |
offset |
number |
não |
type ListItemsQuery = { "highlighted"?: boolean; "related_to"?: string | number; "category"?: string | number; "brand"?: string; "q"?: string; "limit"?: number; "offset"?: number; };type ListItemsResponse = unknown;Exemplo
Seção intitulada “Exemplo”const response = await sdk.ecommerce.listItems();Testar esta função no playground
redeemItem
Seção intitulada “redeemItem”POST
/ecommerce/items/:id/redeemAssinatura:
redeemItem(id: string, settings?: SdkSettings): Promise<RedeemItemResponse>Parâmetros de rota
Seção intitulada “Parâmetros de rota”| Nome | Tipo |
|---|---|
id |
string |
type RedeemItemParams = { "id": string; };type RedeemItemResponse = unknown;Exemplo
Seção intitulada “Exemplo”const response = await sdk.ecommerce.redeemItem("string");