chore(docs): Generated References (automated) (#13544)
Generated the following references: - `api_key_models` - `auth_models` - `cart_models` - `core_flows` - `currency_models` - `customer_models` - `fulfillment_models` - `inventory_next_models` - `js_sdk` - `modules` - `order` - `order_models` - `payment_models` - `pricing_models` - `product_models` - `promotion_models` - `region_models` - `sales_channel_models` - `stock_location_next_models` - `store_models` - `tax_models` - `types` - `user_models` Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com> Co-authored-by: Shahed Nasser <27354907+shahednasser@users.noreply.github.com>
This commit is contained in:
528 files changed
+249559
-245963
No files matched your search
+170
@@ -0,0 +1,170 @@
|
||||
---
|
||||
slug: /references/js-sdk/admin/views
|
||||
sidebar_label: views
|
||||
tags:
|
||||
- js sdk
|
||||
- admin
|
||||
- views
|
||||
---
|
||||
|
||||
import { TypeList } from "docs-ui"
|
||||
|
||||
# views - JS SDK Admin Reference
|
||||
|
||||
:::note
|
||||
|
||||
To use this resource, make sure to [enable its feature flag: view_configurations](https://docs.medusajs.com/development/feature-flags/toggle)
|
||||
|
||||
:::
|
||||
|
||||
This documentation provides a reference to the `sdk.admin.views` set of methods used to send requests to Medusa's Admin API routes.
|
||||
|
||||
## constructor
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"client","type":"[Client](../../../classes/js_sdk.admin.Client/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"fetch_","type":"[ClientFetch](../../../types/js_sdk.admin.ClientFetch/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"config","type":"[Config](../../../types/js_sdk.admin.Config/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"baseUrl","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"globalHeaders","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"publishableKey","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"apiKey","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"auth","type":"`object`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"logger","type":"[Logger](../../../types/js_sdk.admin.Logger/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"debug","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"logger","type":"[Logger](../../../types/js_sdk.admin.Logger/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"error","type":"(...`messages`: `string`[]) => `void`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"warn","type":"(...`messages`: `string`[]) => `void`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"info","type":"(...`messages`: `string`[]) => `void`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"debug","type":"(...`messages`: `string`[]) => `void`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"DEFAULT_JWT_STORAGE_KEY","type":"`string`","description":"","optional":false,"defaultValue":"\"medusa_auth_token\"","expandable":false,"children":[]},{"name":"token","type":"`string`","description":"","optional":false,"defaultValue":"\"\"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="Views"/>
|
||||
|
||||
___
|
||||
|
||||
## columns
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[SelectParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.SelectParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="columns"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewsEntityColumnsResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewsEntityColumnsResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"columns","type":"[AdminColumn](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminColumn/page.mdx)[]","description":"The list of available columns for the entity.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The column's unique identifier (e.g., \"display\\_id\", \"customer.email\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The display name for the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"field","type":"`string`","description":"The field path to access the data.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sortable","type":"`boolean`","description":"Whether the column can be sorted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"hideable","type":"`boolean`","description":"Whether the column can be hidden.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_visible","type":"`boolean`","description":"Whether the column is visible by default.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data_type","type":"`\"string\"` \\| `\"number\"` \\| `\"boolean\"` \\| `\"object\"` \\| `\"enum\"` \\| `\"currency\"` \\| `\"date\"`","description":"The data type of the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"Description of the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"semantic_type","type":"`string`","description":"The semantic type provides additional context about the data.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"`string`","description":"Additional context about the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"computed","type":"`object`","description":"Information about computed columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"relationship","type":"`object`","description":"Information about relationship columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_order","type":"`number`","description":"Default order for sorting columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"category","type":"`\"metadata\"` \\| `\"status\"` \\| `\"identifier\"` \\| `\"timestamp\"` \\| `\"metric\"` \\| `\"relationship\"`","description":"Category for grouping columns.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="columns"/>
|
||||
|
||||
___
|
||||
|
||||
## listConfigurations
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"and\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"and\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"or\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"limit","type":"`number`","description":"The maximum number of items to retrieve.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"offset","type":"`number`","description":"The number of items to skip before retrieving the returned items.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"order","type":"`string`","description":"The field to sort by and in which order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"IDs to filter view configurations by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string` \\| `string`[]","description":"Entity to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| `string`[]","description":"Name to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string` \\| `string`[]","description":"User ID to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Filter by system default status.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"[OperatorMap](../../../../../types/DAL/types/types.DAL.OperatorMap/page.mdx)<string>","description":"Date filters for when the view configuration was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"[OperatorMap](../../../../../types/DAL/types/types.DAL.OperatorMap/page.mdx)<string>","description":"Date filters for when the view configuration was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"or\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetVLine truncated
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationListResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationListResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"limit","type":"`number`","description":"The maximum number of items retrieved.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"offset","type":"`number`","description":"The number of items to skip before retrieving the returned items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"count","type":"`number`","description":"The total number of items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"estimate_count","type":"`number`","description":"The estimated count retrieved from the PostgreSQL query planner, which may be inaccurate.","optional":true,"defaultValue":"","expandable":false,"featureFlag":"index_engine","children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="listConfigurations"/>
|
||||
|
||||
___
|
||||
|
||||
## createConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"[AdminCreateViewConfiguration](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateViewConfiguration/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"visible_columns","type":"`string`[]","description":"The list of visible column IDs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"column_order","type":"`string`[]","description":"The order of columns.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"column_widths","type":"`Record<string, number>`","description":"Custom column widths.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Active filters for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sorting","type":"`null` \\| `object`","description":"Sorting configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"search","type":"`string`","description":"Search query for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"set_active","type":"`boolean`","description":"Whether to set this view as the active view after creation.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="createConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="createConfiguration"/>
|
||||
|
||||
___
|
||||
|
||||
## retrieveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[SelectParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.SelectParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveConfiguration"/>
|
||||
|
||||
___
|
||||
|
||||
## updateConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"[AdminUpdateViewConfiguration](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateViewConfiguration/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"set_active","type":"`boolean`","description":"Whether to set this view as the active view after update.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"visible_columns","type":"`string`[]","description":"The list of visible column IDs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"column_order","type":"`string`[]","description":"The order of columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"column_widths","type":"`Record<string, number>`","description":"Custom column widths.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Active filters for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sorting","type":"`null` \\| `object`","description":"Sorting configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"search","type":"`string`","description":"Search query for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="updateConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="updateConfiguration"/>
|
||||
|
||||
___
|
||||
|
||||
## deleteConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="deleteConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationDeleteResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationDeleteResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"id","type":"`string`","description":"The ID of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"object","type":"TObject","description":"The type of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted","type":"`boolean`","description":"Whether the item was deleted successfully.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="deleteConfiguration"/>
|
||||
|
||||
___
|
||||
|
||||
## retrieveActiveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveActiveConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx) & object>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"AdminViewConfigurationResponse","type":"`object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"active_view_configuration_id","type":"`null` \\| `string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveActiveConfiguration"/>
|
||||
|
||||
___
|
||||
|
||||
## setActiveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"`object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"view_configuration_id","type":"`null` \\| `string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="setActiveConfiguration"/>
|
||||
|
||||
### Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<object>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"success","type":"`boolean`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="setActiveConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# columns
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[SelectParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.SelectParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="columns"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewsEntityColumnsResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewsEntityColumnsResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"columns","type":"[AdminColumn](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminColumn/page.mdx)[]","description":"The list of available columns for the entity.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The column's unique identifier (e.g., \"display\\_id\", \"customer.email\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The display name for the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"field","type":"`string`","description":"The field path to access the data.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sortable","type":"`boolean`","description":"Whether the column can be sorted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"hideable","type":"`boolean`","description":"Whether the column can be hidden.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_visible","type":"`boolean`","description":"Whether the column is visible by default.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data_type","type":"`\"string\"` \\| `\"number\"` \\| `\"boolean\"` \\| `\"object\"` \\| `\"enum\"` \\| `\"currency\"` \\| `\"date\"`","description":"The data type of the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"Description of the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"semantic_type","type":"`string`","description":"The semantic type provides additional context about the data.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"`string`","description":"Additional context about the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"computed","type":"`object`","description":"Information about computed columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"relationship","type":"`object`","description":"Information about relationship columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_order","type":"`number`","description":"Default order for sorting columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"category","type":"`\"metadata\"` \\| `\"status\"` \\| `\"identifier\"` \\| `\"timestamp\"` \\| `\"metric\"` \\| `\"relationship\"`","description":"Category for grouping columns.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="columns"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewsEntityColumnsResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewsEntityColumnsResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"columns","type":"[AdminColumn](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminColumn/page.mdx)[]","description":"The list of available columns for the entity.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The column's unique identifier (e.g., \"display\\_id\", \"customer.email\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The display name for the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"field","type":"`string`","description":"The field path to access the data.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sortable","type":"`boolean`","description":"Whether the column can be sorted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"hideable","type":"`boolean`","description":"Whether the column can be hidden.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_visible","type":"`boolean`","description":"Whether the column is visible by default.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data_type","type":"`\"string\"` \\| `\"number\"` \\| `\"boolean\"` \\| `\"object\"` \\| `\"enum\"` \\| `\"currency\"` \\| `\"date\"`","description":"The data type of the column.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"Description of the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"semantic_type","type":"`string`","description":"The semantic type provides additional context about the data.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"`string`","description":"Additional context about the column.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"computed","type":"`object`","description":"Information about computed columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"relationship","type":"`object`","description":"Information about relationship columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_order","type":"`number`","description":"Default order for sorting columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"category","type":"`\"metadata\"` \\| `\"status\"` \\| `\"identifier\"` \\| `\"timestamp\"` \\| `\"metric\"` \\| `\"relationship\"`","description":"Category for grouping columns.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="columns"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# createConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"[AdminCreateViewConfiguration](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateViewConfiguration/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"visible_columns","type":"`string`[]","description":"The list of visible column IDs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"column_order","type":"`string`[]","description":"The order of columns.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"column_widths","type":"`Record<string, number>`","description":"Custom column widths.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Active filters for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sorting","type":"`null` \\| `object`","description":"Sorting configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"search","type":"`string`","description":"Search query for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"set_active","type":"`boolean`","description":"Whether to set this view as the active view after creation.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="createConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="createConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="createConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# deleteConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="deleteConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationDeleteResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationDeleteResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"object","type":"TObject","description":"The type of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted","type":"`boolean`","description":"Whether the item was deleted successfully.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="deleteConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationDeleteResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationDeleteResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"id","type":"`string`","description":"The ID of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"object","type":"TObject","description":"The type of the item that was deleted.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted","type":"`boolean`","description":"Whether the item was deleted successfully.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="deleteConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# listConfigurations
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"and\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"and\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"or\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"limit","type":"`number`","description":"The maximum number of items to retrieve.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"offset","type":"`number`","description":"The number of items to skip before retrieving the returned items.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"order","type":"`string`","description":"The field to sort by and in which order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"IDs to filter view configurations by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string` \\| `string`[]","description":"Entity to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| `string`[]","description":"Name to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string` \\| `string`[]","description":"User ID to filter by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Filter by system default status.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"[OperatorMap](../../../../../types/DAL/types/types.DAL.OperatorMap/page.mdx)<string>","description":"Date filters for when the view configuration was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"[OperatorMap](../../../../../types/DAL/types/types.DAL.OperatorMap/page.mdx)<string>","description":"Date filters for when the view configuration was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx) \\| [BaseFilterable](../../../../../types/DAL/interfaces/types.DAL.BaseFilterable/page.mdx)<[AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetViewConfigurationsParams/page.mdx)>)[]","description":"An array of filters to apply on the entity, where each item in the array is joined with an \"or\" condition.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([AdminGetViewConfigurationsParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminGetVLine truncated
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationListResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationListResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"limit","type":"`number`","description":"The maximum number of items retrieved.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"offset","type":"`number`","description":"The number of items to skip before retrieving the returned items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"count","type":"`number`","description":"The total number of items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"estimate_count","type":"`number`","description":"The estimated count retrieved from the PostgreSQL query planner, which may be inaccurate.","optional":true,"defaultValue":"","expandable":false,"featureFlag":"index_engine","children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="listConfigurations"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationListResponse](../../../../../types/HttpTypes/types/types.HttpTypes.AdminViewConfigurationListResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"limit","type":"`number`","description":"The maximum number of items retrieved.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"offset","type":"`number`","description":"The number of items to skip before retrieving the returned items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"count","type":"`number`","description":"The total number of items.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"estimate_count","type":"`number`","description":"The estimated count retrieved from the PostgreSQL query planner, which may be inaccurate.","optional":true,"defaultValue":"","expandable":false,"featureFlag":"index_engine","children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="listConfigurations"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# retrieveActiveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveActiveConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx) & object>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"AdminViewConfigurationResponse","type":"`object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"active_view_configuration_id","type":"`null` \\| `string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveActiveConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx) & object>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"AdminViewConfigurationResponse","type":"`object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"active_view_configuration_id","type":"`null` \\| `string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveActiveConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# retrieveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"query","type":"[SelectParams](../../../../../types/HttpTypes/interfaces/types.HttpTypes.SelectParams/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"fields","type":"`string`","description":"The fields and relations to retrieve separated by commas.\n\nLearn more in the [API reference](https://docs.medusajs.com/api/store#select-fields-and-relations).","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="retrieveConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# setActiveConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"`object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"view_configuration_id","type":"`null` \\| `string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="setActiveConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<object>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"success","type":"`boolean`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="setActiveConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<object>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"success","type":"`boolean`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="setActiveConfiguration"/>
|
||||
+7
-1
@@ -2,10 +2,16 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
# updateConfiguration
|
||||
|
||||
:::note
|
||||
|
||||
This is available starting from Medusa `v2.10.3`.
|
||||
|
||||
:::
|
||||
|
||||
## Parameters
|
||||
|
||||
<TypeList types={[{"name":"entity","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"body","type":"[AdminUpdateViewConfiguration](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateViewConfiguration/page.mdx)","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"set_active","type":"`boolean`","description":"Whether to set this view as the active view after update.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"visible_columns","type":"`string`[]","description":"The list of visible column IDs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"column_order","type":"`string`[]","description":"The order of columns.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"column_widths","type":"`Record<string, number>`","description":"Custom column widths.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Active filters for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sorting","type":"`null` \\| `object`","description":"Sorting configuration.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"search","type":"`string`","description":"Search query for the view.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]},{"name":"headers","type":"[ClientHeaders](../../../types/js_sdk.admin.ClientHeaders/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"tags","type":"`string`[]","description":"Tags to cache data under for Next.js applications.\n\nLearn more in [Next.js's documentation](https://nextjs.org/docs/app/building-your-application/caching#fetch-optionsnexttags-and-revalidatetag).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="updateConfiguration"/>
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="updateConfiguration"/>
|
||||
<TypeList types={[{"name":"Promise","type":"Promise<[AdminViewConfigurationResponse](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminViewConfigurationResponse/page.mdx)>","optional":false,"defaultValue":"","description":"","expandable":false,"featureFlag":"view_configurations","children":[{"name":"view_configuration","type":"`null` \\| [AdminViewConfiguration](../../../../../types/interfaces/types.AdminViewConfiguration/page.mdx)","description":"The view configuration's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The view configuration's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity","type":"`string`","description":"The entity this configuration is for (e.g., \"order\", \"product\").","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`null` \\| `string`","description":"The name of the view configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"user_id","type":"`null` \\| `string`","description":"The ID of the user who owns this configuration, or null for system defaults.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_system_default","type":"`boolean`","description":"Whether this is a system default configuration.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"configuration","type":"`object`","description":"The view configuration settings.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`Date`","description":"The date the view configuration was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`Date`","description":"The date the view configuration was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="updateConfiguration"/>
|
||||
@@ -54,4 +54,5 @@ The `sdk.admin` class provides methods to send requests to Medusa's Admin API ro
|
||||
- [taxRegion](../../Admin/properties/js_sdk.admin.Admin.taxRegion/page.mdx)
|
||||
- [upload](../../Admin/properties/js_sdk.admin.Admin.upload/page.mdx)
|
||||
- [user](../../Admin/properties/js_sdk.admin.Admin.user/page.mdx)
|
||||
- [views](../../Admin/properties/js_sdk.admin.Admin.views/page.mdx)
|
||||
- [workflowExecution](../../Admin/properties/js_sdk.admin.Admin.workflowExecution/page.mdx)
|
||||
+1
@@ -273,6 +273,7 @@ This method updates the customer of a cart.
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to set the cart's customer
|
||||
sdk.store.cart.transferCart("cart_123")
|
||||
.then(({ cart }) => {
|
||||
console.log(cart)
|
||||
|
||||
+10
@@ -68,6 +68,7 @@ Related guide: [How to edit customer's profile in the storefront](https://docs.m
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to update their details
|
||||
sdk.store.customer.update({
|
||||
first_name: "John"
|
||||
})
|
||||
@@ -97,6 +98,7 @@ API route.
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to retrieve their details
|
||||
sdk.store.customer.retrieve()
|
||||
.then(({ customer }) => {
|
||||
console.log(customer)
|
||||
@@ -126,6 +128,7 @@ Related guides: [How to manage customer's addresses in the storefront](https://d
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to create an address
|
||||
sdk.store.customer.createAddress({
|
||||
country_code: "us"
|
||||
})
|
||||
@@ -157,6 +160,7 @@ Related guides: [How to manage customer's addresses in the storefront](https://d
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to update their address
|
||||
sdk.store.customer.updateAddress(
|
||||
"caddr_123",
|
||||
{
|
||||
@@ -193,6 +197,7 @@ Related guides: [How to manage customer's addresses in the storefront](https://d
|
||||
To retrieve the list of addresses:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their addresses
|
||||
sdk.store.customer.listAddress()
|
||||
.then(({ addresses, count, offset, limit }) => {
|
||||
console.log(addresses)
|
||||
@@ -204,6 +209,7 @@ To configure the pagination, pass the `limit` and `offset` query parameters.
|
||||
For example, to retrieve only 10 items and skip 10 items:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their addresses
|
||||
sdk.store.customer.listAddress({
|
||||
limit: 10,
|
||||
offset: 10
|
||||
@@ -217,6 +223,7 @@ Using the `fields` query parameter, you can specify the fields and relations to
|
||||
in each address:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their addresses
|
||||
sdk.store.customer.listAddress({
|
||||
fields: "id,country_code"
|
||||
})
|
||||
@@ -252,6 +259,7 @@ Related guides: [How to manage customer's addresses in the storefront](https://d
|
||||
To retrieve an address by its ID:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to retrieve their address
|
||||
sdk.store.customer.retrieveAddress(
|
||||
"caddr_123"
|
||||
)
|
||||
@@ -263,6 +271,7 @@ sdk.store.customer.retrieveAddress(
|
||||
To specify the fields and relations to retrieve:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to retrieve their address
|
||||
sdk.store.customer.retrieveAddress(
|
||||
"caddr_123",
|
||||
{
|
||||
@@ -299,6 +308,7 @@ Related guides: [How to manage customer's addresses in the storefront](https://d
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to delete their address
|
||||
sdk.store.customer.deleteAddress("caddr_123")
|
||||
.then(({ deleted, parent: customer }) => {
|
||||
console.log(customer)
|
||||
|
||||
+5
@@ -24,6 +24,7 @@ API route.
|
||||
To retrieve the list of orders:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their orders
|
||||
sdk.store.order.list()
|
||||
.then(({ orders, count, offset, limit }) => {
|
||||
console.log(orders)
|
||||
@@ -35,6 +36,7 @@ To configure the pagination, pass the `limit` and `offset` query parameters.
|
||||
For example, to retrieve only 10 items and skip 10 items:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their orders
|
||||
sdk.store.order.list({
|
||||
limit: 10,
|
||||
offset: 10
|
||||
@@ -48,6 +50,7 @@ Using the `fields` query parameter, you can specify the fields and relations to
|
||||
in each order:
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to list their orders
|
||||
sdk.store.order.list({
|
||||
fields: "id,*items"
|
||||
})
|
||||
@@ -116,6 +119,7 @@ Customer requesting the transfer must be logged in.
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to request the order transfer
|
||||
sdk.store.order.requestTransfer(
|
||||
"order_123",
|
||||
{
|
||||
@@ -150,6 +154,7 @@ Customer requesting the transfer must be logged in.
|
||||
### Example
|
||||
|
||||
```ts
|
||||
// TODO must be authenticated as the customer to cancel the order transfer
|
||||
sdk.store.order.cancelTransfer(
|
||||
"order_123",
|
||||
{},
|
||||
|
||||
+1
-1
@@ -107,7 +107,7 @@ sdk.store.payment.initiatePaymentSession(
|
||||
|
||||
### Parameters
|
||||
|
||||
<TypeList types={[{"name":"cart","type":"[StoreCart](../../../../../types/HttpTypes/interfaces/types.HttpTypes.StoreCart/page.mdx)","description":"The cart's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency of the cart","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_total","type":"`number`","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_subtotal","type":"`number`","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_tax_total","type":"`number`","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_total","type":"`number`","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_subtotal","type":"`number`","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_tax_total","type":"`number`","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_total","type":"`number`","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_subtotal","type":"`number`","description":"The original subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_tax_total","type":"`number`","description":"The original tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"total","type":"`number`","description":"The total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtotal","type":"`number`","description":"The subtotal of the cart. (Excluding taxes)","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_total","type":"`number`","description":"The tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_total","type":"`number`","description":"The discount total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_tax_total","type":"`number`","description":"The discount tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"gift_card_total","type":"`number`","description":"The gift card total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"gift_card_tax_total","type":"`number`","description":"The gift card tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_total","type":"`number`","description":"The shipping total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_subtotal","type":"`number`","description":"The shipping subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_tax_total","type":"`number`","description":"The shipping tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_total","type":"`number`","description":"The original shipping total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_subtotal","type":"`number`","description":"The original shipping subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_tax_total","type":"`number`","description":"The original shipping tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotions","type":"[StoreCartPromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.StoreCartPromotion/page.mdx)[]","description":"The promotions applied to the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically (without the customer needing to enter a code).","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"application_method","type":"`object`","description":"How the promoLine truncated
|
||||
<TypeList types={[{"name":"cart","type":"[StoreCart](../../../../../types/HttpTypes/interfaces/types.HttpTypes.StoreCart/page.mdx)","description":"The cart's details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency of the cart","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_total","type":"`number`","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_subtotal","type":"`number`","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_item_tax_total","type":"`number`","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_total","type":"`number`","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_subtotal","type":"`number`","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_tax_total","type":"`number`","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_total","type":"`number`","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_subtotal","type":"`number`","description":"The original subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_tax_total","type":"`number`","description":"The original tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"total","type":"`number`","description":"The total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtotal","type":"`number`","description":"The subtotal of the cart. (Excluding taxes)","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_total","type":"`number`","description":"The tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_total","type":"`number`","description":"The discount total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_tax_total","type":"`number`","description":"The discount tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"gift_card_total","type":"`number`","description":"The gift card total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"gift_card_tax_total","type":"`number`","description":"The gift card tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_total","type":"`number`","description":"The shipping total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_subtotal","type":"`number`","description":"The shipping subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_tax_total","type":"`number`","description":"The shipping tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_total","type":"`number`","description":"The original shipping total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_subtotal","type":"`number`","description":"The original shipping subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_shipping_tax_total","type":"`number`","description":"The original shipping tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotions","type":"[StoreCartPromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.StoreCartPromotion/page.mdx)[]","description":"The promotions applied to the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically (without the customer needing to enter a code).","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"application_method","type":"`object`","description":"How the promoLine truncated
|
||||
|
||||
### Returns
|
||||
|
||||
|
||||
Reference in new issue
Block a user