docs: fixes for core workflows reference (#11056)
* docs: fix step input / output description not showing * fix generated example for array types * show workflow summary in diagram * fix workflow node width * hide undefined types
This commit is contained in:
1 parent
af350c3a8b
commit
0d18d5854a
484 files changed
+1172
-1128
No files matched your search
+1
-1
@@ -8,4 +8,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
+1
-1
@@ -8,4 +8,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
+1
-1
@@ -134,7 +134,7 @@ class MyAuthProviderService extends AbstractAuthModuleProvider {
|
||||
|
||||
#### Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"This method validates the options of the provider set in `medusa-config.ts`.\nImplementing this method is optional. It's useful if your provider requires custom validation.\n\nIf the options aren't valid, throw an error.","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="validateOptions"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="validateOptions"/>
|
||||
|
||||
### authenticate
|
||||
|
||||
|
||||
+1
-1
@@ -8,4 +8,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="clearMessages"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="save"/>
|
||||
+1
-1
@@ -12,4 +12,4 @@ import { TypeList } from "docs-ui"
|
||||
|
||||
## Returns
|
||||
|
||||
<TypeList types={[{"name":"void","type":"`void`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
<TypeList types={[]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="saveRawMessageData"/>
|
||||
+1
-1
@@ -30,7 +30,7 @@ const data = createApiKeysStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateApiKeysStepInput","type":"[CreateApiKeysStepInput](../../../../types/core_flows.CreateApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"api_keys","type":"[CreateApiKeyDTO](../../../../../api_key/interfaces/api_key.CreateApiKeyDTO/page.mdx)[]","description":"The API keys to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the API key.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"The type of the API key.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`string`","description":"Who created the API key.\nIf the API key type is `secret`, the user can use the created API key's token to authenticate\nas explained in the [API Reference](https://docs.medusajs.com/api/admin#2-api-token).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createApiKeysStep"/>
|
||||
<TypeList types={[{"name":"CreateApiKeysStepInput","type":"[CreateApiKeysStepInput](../../../../types/core_flows.CreateApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create API keys.","expandable":false,"children":[{"name":"api_keys","type":"[CreateApiKeyDTO](../../../../../api_key/interfaces/api_key.CreateApiKeyDTO/page.mdx)[]","description":"The API keys to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the API key.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"The type of the API key.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`string`","description":"Who created the API key.\nIf the API key type is `secret`, the user can use the created API key's token to authenticate\nas explained in the [API Reference](https://docs.medusajs.com/api/admin#2-api-token).","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createApiKeysStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteApiKeysStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteApiKeysStep({})
|
||||
const data = deleteApiKeysStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteApiKeysStepInput","type":"[DeleteApiKeysStepInput](../../../../types/core_flows.DeleteApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteApiKeysStepInput","type":"`string`[]","description":"The IDs of the API keys to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteApiKeysStep"/>
|
||||
<TypeList types={[{"name":"DeleteApiKeysStepInput","type":"[DeleteApiKeysStepInput](../../../../types/core_flows.DeleteApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the API keys to delete.","expandable":false,"children":[{"name":"DeleteApiKeysStepInput","type":"`string`[]","description":"The IDs of the API keys to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteApiKeysStep"/>
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = revokeApiKeysStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RevokeApiKeysStepInput","type":"[RevokeApiKeysStepInput](../../../../types/core_flows.RevokeApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"selector","type":"[FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx)","description":"The filters to select the API keys to revoke.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Search through the api key names and redacted keys using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"token","type":"`string` \\| `string`[]","description":"The tokens to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"title","type":"`string` \\| `string`[]","description":"The titles to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"Filter the API keys by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"revoked_at","type":"[OperatorMap](../../../../../api_key/types/api_key.OperatorMap/page.mdx)<null \\| Date>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$and","type":"([FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx) \\| [BaseFilterable](../../../../../api_key/interfaces/api_key.BasLine truncated
|
||||
<TypeList types={[{"name":"RevokeApiKeysStepInput","type":"[RevokeApiKeysStepInput](../../../../types/core_flows.RevokeApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to revoke API keys.","expandable":false,"children":[{"name":"selector","type":"[FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx)","description":"The filters to select the API keys to revoke.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Search through the api key names and redacted keys using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"token","type":"`string` \\| `string`[]","description":"The tokens to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"title","type":"`string` \\| `string`[]","description":"The titles to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"Filter the API keys by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"revoked_at","type":"[OperatorMap](../../../../../api_key/types/api_key.OperatorMap/page.mdx)<null \\| Date>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$and","type":"([FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx) \\| [BaseFilterable](../../../../../apLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateApiKeysStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateApiKeysStepInput","type":"[UpdateApiKeysStepInput](../../../../types/core_flows.UpdateApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"selector","type":"[FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx)","description":"The filters to select the API keys to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Search through the api key names and redacted keys using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"token","type":"`string` \\| `string`[]","description":"The tokens to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"title","type":"`string` \\| `string`[]","description":"The titles to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"Filter the API keys by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"revoked_at","type":"[OperatorMap](../../../../../api_key/types/api_key.OperatorMap/page.mdx)<null \\| Date>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$and","type":"([FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx) \\| [BaseFilterable](../../../../../api_key/interfaces/api_key.BasLine truncated
|
||||
<TypeList types={[{"name":"UpdateApiKeysStepInput","type":"[UpdateApiKeysStepInput](../../../../types/core_flows.UpdateApiKeysStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update API keys.","expandable":false,"children":[{"name":"selector","type":"[FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx)","description":"The filters to select the API keys to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Search through the api key names and redacted keys using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"token","type":"`string` \\| `string`[]","description":"The tokens to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"title","type":"`string` \\| `string`[]","description":"The titles to filter the API keys by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApiKeyType](../../../../../api_key/types/api_key.ApiKeyType/page.mdx)","description":"Filter the API keys by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"revoked_at","type":"[OperatorMap](../../../../../api_key/types/api_key.OperatorMap/page.mdx)<null \\| Date>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../api_key/types/api_key.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../api_key/types/api_key.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$and","type":"([FilterableApiKeyProps](../../../../../api_key/interfaces/api_key.FilterableApiKeyProps/page.mdx) \\| [BaseFilterable](../../../../../apLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateSalesChannelsExistStepInput","type":"[ValidateSalesChannelsExistStepInput](../../../../interfaces/core_flows.ValidateSalesChannelsExistStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"sales_channel_ids","type":"`string`[]","description":"The IDs of the sales channels to validate.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateSalesChannelsExistStep"/>
|
||||
<TypeList types={[{"name":"ValidateSalesChannelsExistStepInput","type":"[ValidateSalesChannelsExistStepInput](../../../../interfaces/core_flows.ValidateSalesChannelsExistStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to validate that the sales channels exist.","expandable":false,"children":[{"name":"sales_channel_ids","type":"`string`[]","description":"The IDs of the sales channels to validate.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateSalesChannelsExistStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -50,4 +50,4 @@ const data = setAuthAppMetadataStep({
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"AuthIdentityDTO","type":"[AuthIdentityDTO](../../../../../auth/interfaces/auth.AuthIdentityDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the auth identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_identities","type":"[ProviderIdentityDTO](../../../../../auth/interfaces/auth.ProviderIdentityDTO/page.mdx)[]","description":"The list of provider identities linked to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the provider identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity_id","type":"`string`","description":"The user's identifier. For example, when using the `emailpass`\nprovider, the `entity_id` would be the user's email.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"auth_identity_id","type":"`string`","description":"The ID of the auth identity linked to the provider identity.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"auth_identity","type":"[AuthIdentityDTO](../../../../../auth/interfaces/auth.AuthIdentityDTO/page.mdx)","description":"The auth identity linked to the provider identity.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the auth identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_identities","type":"[ProviderIdentityDTO](../../../../../auth/interfaces/auth.ProviderIdentityDTO/page.mdx)[]","description":"The list of provider identities linked to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"app_metadata","type":"`Record<string, unknown>`","description":"Holds information related to the actor IDs tied to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"provider_metadata","type":"`Record<string, unknown>`","description":"Holds custom data related to the provider in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"user_metadata","type":"`Record<string, unknown>`","description":"Holds custom data related to the user in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"app_metadata","type":"`Record<string, unknown>`","description":"Holds information related to the actor IDs tied to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="setAuthAppMetadataStep"/>
|
||||
<TypeList types={[{"name":"AuthIdentityDTO","type":"[AuthIdentityDTO](../../../../../auth/interfaces/auth.AuthIdentityDTO/page.mdx)","optional":false,"defaultValue":"","description":"The auth identity details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the auth identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_identities","type":"[ProviderIdentityDTO](../../../../../auth/interfaces/auth.ProviderIdentityDTO/page.mdx)[]","description":"The list of provider identities linked to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the provider identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"entity_id","type":"`string`","description":"The user's identifier. For example, when using the `emailpass`\nprovider, the `entity_id` would be the user's email.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"auth_identity_id","type":"`string`","description":"The ID of the auth identity linked to the provider identity.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"auth_identity","type":"[AuthIdentityDTO](../../../../../auth/interfaces/auth.AuthIdentityDTO/page.mdx)","description":"The auth identity linked to the provider identity.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the auth identity.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_identities","type":"[ProviderIdentityDTO](../../../../../auth/interfaces/auth.ProviderIdentityDTO/page.mdx)[]","description":"The list of provider identities linked to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"app_metadata","type":"`Record<string, unknown>`","description":"Holds information related to the actor IDs tied to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"provider_metadata","type":"`Record<string, unknown>`","description":"Holds custom data related to the provider in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"user_metadata","type":"`Record<string, unknown>`","description":"Holds custom data related to the user in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"app_metadata","type":"`Record<string, unknown>`","description":"Holds information related to the actor IDs tied to the auth identity.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="setAuthAppMetadataStep"/>
|
||||
+1
-1
@@ -30,7 +30,7 @@ const data = addShippingMethodToCartStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"AddShippingMethodToCartStepInput","type":"[AddShippingMethodToCartStepInput](../../../../interfaces/core_flows.AddShippingMethodToCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"shipping_methods","type":"[CreateShippingMethodDTO](../../../../../cart/interfaces/cart.CreateShippingMethodDTO/page.mdx)[]","description":"The shipping methods to add.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shipping_option_id","type":"`string`","description":"The amount of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The data of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_lines","type":"[CreateTaxLineDTO](../../../../../cart/interfaces/cart.CreateTaxLineDTO/page.mdx)[]","description":"The tax lines of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rate","type":"`number`","description":"The rate of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the tax line.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_rate_id","type":"`string`","description":"The associated tax rate's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"adjustments","type":"[CreateAdjustmentDTO](../../../../../cart/interfaces/cart.CreateAdjustmentDTO/page.mdx)[]","description":"The adjustments of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="addShippingMethodToCartStep"/>
|
||||
<TypeList types={[{"name":"AddShippingMethodToCartStepInput","type":"[AddShippingMethodToCartStepInput](../../../../interfaces/core_flows.AddShippingMethodToCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping methods to add.","expandable":false,"children":[{"name":"shipping_methods","type":"[CreateShippingMethodDTO](../../../../../cart/interfaces/cart.CreateShippingMethodDTO/page.mdx)[]","description":"The shipping methods to add.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shipping_option_id","type":"`string`","description":"The amount of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The data of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_lines","type":"[CreateTaxLineDTO](../../../../../cart/interfaces/cart.CreateTaxLineDTO/page.mdx)[]","description":"The tax lines of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rate","type":"`number`","description":"The rate of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the tax line.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_rate_id","type":"`string`","description":"The associated tax rate's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"adjustments","type":"[CreateAdjustmentDTO](../../../../../cart/interfaces/cart.CreateAdjustmentDTO/page.mdx)[]","description":"The adjustments of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="addShippingMethodToCartStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -33,4 +33,4 @@ confirmInventoryStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ConfirmVariantInventoryStepInput","type":"[ConfirmVariantInventoryStepInput](../../../../interfaces/core_flows.ConfirmVariantInventoryStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The items to confirm inventory for.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the inventory item associated with the line item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"required_quantity","type":"`number`","description":"The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the\nvalue set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"allow_backorder","type":"`boolean`","description":"Whether the variant can be ordered even if it's out of stock. If a variant has this enabled, the step doesn't throw an error.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location_ids","type":"`string`[]","description":"The ID of the stock locations that the inventory quantity is available in.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="confirmInventoryStep"/>
|
||||
<TypeList types={[{"name":"ConfirmVariantInventoryStepInput","type":"[ConfirmVariantInventoryStepInput](../../../../interfaces/core_flows.ConfirmVariantInventoryStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart items to confirm their inventory availability.","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The items to confirm inventory for.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the inventory item associated with the line item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"required_quantity","type":"`number`","description":"The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the\nvalue set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"allow_backorder","type":"`boolean`","description":"Whether the variant can be ordered even if it's out of stock. If a variant has this enabled, the step doesn't throw an error.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location_ids","type":"`string`[]","description":"The ID of the stock locations that the inventory quantity is available in.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="confirmInventoryStep"/>
|
||||
+2
-2
@@ -22,7 +22,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createCartsStep({
|
||||
"currency_code": "gip"
|
||||
"currency_code": "mxn"
|
||||
})
|
||||
}
|
||||
)
|
||||
@@ -31,7 +31,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateCartsStepInput","type":"[CreateCartsStepInput](../../../../types/core_flows.CreateCartsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"The currency code of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"region_id","type":"`string`","description":"The associated region's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel_id","type":"`string`","description":"The associated sales channel's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer that owns the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address_id","type":"`string`","description":"The associated shipping address's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"billing_address_id","type":"`string`","description":"The associated billing address's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"`string` \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The shipping address of the cart.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"billing_address","type":"`string` \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The billing address of the cart.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","Line truncated
|
||||
<TypeList types={[{"name":"CreateCartsStepInput","type":"[CreateCartsStepInput](../../../../types/core_flows.CreateCartsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the carts to create.","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"The currency code of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"region_id","type":"`string`","description":"The associated region's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel_id","type":"`string`","description":"The associated sales channel's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer that owns the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address_id","type":"`string`","description":"The associated shipping address's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"billing_address_id","type":"`string`","description":"The associated billing address's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"`string` \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The shipping address of the cart.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"billing_address","type":"`string` \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The billing address of the cart.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","descriptioLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -30,4 +30,4 @@ createLineItemAdjustmentsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateLineItemAdjustmentsCartStepInput","type":"[CreateLineItemAdjustmentsCartStepInput](../../../../interfaces/core_flows.CreateLineItemAdjustmentsCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"lineItemAdjustmentsToCreate","type":"[CreateLineItemAdjustmentDTO](../../../../../cart/interfaces/cart.CreateLineItemAdjustmentDTO/page.mdx)[]","description":"The line item adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createLineItemAdjustmentsStep"/>
|
||||
<TypeList types={[{"name":"CreateLineItemAdjustmentsCartStepInput","type":"[CreateLineItemAdjustmentsCartStepInput](../../../../interfaces/core_flows.CreateLineItemAdjustmentsCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line item adjustments to create.","expandable":false,"children":[{"name":"lineItemAdjustmentsToCreate","type":"[CreateLineItemAdjustmentDTO](../../../../../cart/interfaces/cart.CreateLineItemAdjustmentDTO/page.mdx)[]","description":"The line item adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createLineItemAdjustmentsStep"/>
|
||||
+1
-1
@@ -30,7 +30,7 @@ const data = createLineItemsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateLineItemsCartStepInput","type":"[CreateLineItemsCartStepInput](../../../../interfaces/core_flows.CreateLineItemsCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to create line items for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CreateLineItemForCartDTO](../../../../../cart/interfaces/cart.CreateLineItemForCartDTO/page.mdx)[]","description":"The line items to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The quantity of the line item in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"unit_price","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The unit price of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The associated product's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type_id","type":"`string`","description":"The ID of type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The collection of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_id","type":"`string`","description":"The associated variant's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The option values of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"nLine truncated
|
||||
<TypeList types={[{"name":"CreateLineItemsCartStepInput","type":"[CreateLineItemsCartStepInput](../../../../interfaces/core_flows.CreateLineItemsCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line items to create.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to create line items for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CreateLineItemForCartDTO](../../../../../cart/interfaces/cart.CreateLineItemForCartDTO/page.mdx)[]","description":"The line items to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The quantity of the line item in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"unit_price","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The unit price of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The associated product's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type_id","type":"`string`","description":"The ID of type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The collection of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_id","type":"`string`","description":"The associated variant's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The option values of the associated variant.","optional":true,"defaultValue":Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@ const data = createPaymentCollectionsStep([{
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreatePaymentCollectionCartStepInput","type":"[CreatePaymentCollectionCartStepInput](../../../../types/core_flows.CreatePaymentCollectionCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The payment collection's amount.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Custom key-value pairs to store in the payment collection.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createPaymentCollectionsStep"/>
|
||||
<TypeList types={[{"name":"CreatePaymentCollectionCartStepInput","type":"[CreatePaymentCollectionCartStepInput](../../../../types/core_flows.CreatePaymentCollectionCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the payment collections to create.","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The payment collection's amount.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Custom key-value pairs to store in the payment collection.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createPaymentCollectionsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -28,4 +28,4 @@ const data = createShippingMethodAdjustmentsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateShippingMethodAdjustmentsStepInput","type":"[CreateShippingMethodAdjustmentsStepInput](../../../../interfaces/core_flows.CreateShippingMethodAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"shippingMethodAdjustmentsToCreate","type":"[CreateShippingMethodAdjustmentDTO](../../../../../cart/interfaces/cart.CreateShippingMethodAdjustmentDTO/page.mdx)[]","description":"The shipping method adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"shipping_method_id","type":"`string`","description":"The associated shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"description","type":"`string`","description":"The description of the shipping method adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingMethodAdjustmentsStep"/>
|
||||
<TypeList types={[{"name":"CreateShippingMethodAdjustmentsStepInput","type":"[CreateShippingMethodAdjustmentsStepInput](../../../../interfaces/core_flows.CreateShippingMethodAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping method adjustments to create.","expandable":false,"children":[{"name":"shippingMethodAdjustmentsToCreate","type":"[CreateShippingMethodAdjustmentDTO](../../../../../cart/interfaces/cart.CreateShippingMethodAdjustmentDTO/page.mdx)[]","description":"The shipping method adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"shipping_method_id","type":"`string`","description":"The associated shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"description","type":"`string`","description":"The description of the shipping method adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingMethodAdjustmentsStep"/>
|
||||
+2
-2
@@ -30,8 +30,8 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"FindOneOrAnyRegionStepInput","type":"[FindOneOrAnyRegionStepInput](../../../../types/core_flows.FindOneOrAnyRegionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"regionId","type":"`string`","description":"The ID of the region to find.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOneOrAnyRegionStep"/>
|
||||
<TypeList types={[{"name":"FindOneOrAnyRegionStepInput","type":"[FindOneOrAnyRegionStepInput](../../../../types/core_flows.FindOneOrAnyRegionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the region to find.","expandable":false,"children":[{"name":"regionId","type":"`string`","description":"The ID of the region to find.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOneOrAnyRegionStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"RegionDTO","type":"[RegionDTO](../../../../../region/interfaces/region.RegionDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"automatic_taxes","type":"`boolean`","description":"Setting to indicate whether taxes need to be applied automatically","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"countries","type":"[RegionCountryDTO](../../../../../region/interfaces/region.RegionCountryDTO/page.mdx)[]","description":"The countries of the region.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"iso_2","type":"`string`","description":"The ISO 2 code of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"iso_3","type":"`string`","description":"The ISO 3 code of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"num_code","type":"`string`","description":"The country's code number.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"display_name","type":"`string`","description":"The display name of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../region/interfaces/region.PaymentProviderDTO/page.mdx)[]","description":"Payment providers available in the region","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment provider.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_enabled","type":"`boolean`","description":"Whether the payment provider is enabled.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"created_at","type":"`string`","description":"The date the region was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The date the region was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, any>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOneOrAnyRegionStep"/>
|
||||
<TypeList types={[{"name":"RegionDTO","type":"[RegionDTO](../../../../../region/interfaces/region.RegionDTO/page.mdx)","optional":false,"defaultValue":"","description":"The region details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the region.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"automatic_taxes","type":"`boolean`","description":"Setting to indicate whether taxes need to be applied automatically","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"countries","type":"[RegionCountryDTO](../../../../../region/interfaces/region.RegionCountryDTO/page.mdx)[]","description":"The countries of the region.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"iso_2","type":"`string`","description":"The ISO 2 code of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"iso_3","type":"`string`","description":"The ISO 3 code of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"num_code","type":"`string`","description":"The country's code number.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"display_name","type":"`string`","description":"The display name of the country.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../region/interfaces/region.PaymentProviderDTO/page.mdx)[]","description":"Payment providers available in the region","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment provider.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_enabled","type":"`boolean`","description":"Whether the payment provider is enabled.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"created_at","type":"`string`","description":"The date the region was created.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The date the region was updated.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, any>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOneOrAnyRegionStep"/>
|
||||
+2
-2
@@ -31,8 +31,8 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"FindOrCreateCustomerStepInput","type":"[FindOrCreateCustomerStepInput](../../../../interfaces/core_flows.FindOrCreateCustomerStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"customerId","type":"`null` \\| `string`","description":"The ID of the customer to find.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"If the `customerId` isn't specified,\nfind a customer with this email or create a new customer having this email.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOrCreateCustomerStep"/>
|
||||
<TypeList types={[{"name":"FindOrCreateCustomerStepInput","type":"[FindOrCreateCustomerStepInput](../../../../interfaces/core_flows.FindOrCreateCustomerStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the customer to find or create.","expandable":false,"children":[{"name":"customerId","type":"`null` \\| `string`","description":"The ID of the customer to find.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"If the `customerId` isn't specified,\nfind a customer with this email or create a new customer having this email.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findOrCreateCustomerStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"FindOrCreateCustomerOutputStepOutput","type":"[FindOrCreateCustomerOutputStepOutput](../../../../interfaces/core_flows.FindOrCreateCustomerOutputStepOutput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"customer","type":"`null` \\| [CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The customer found or created, if any.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"[CustomerAddressDTO](../../../../../customer/interfaces/customer.CustomerAddressDTO/page.mdx)[]","description":"The addresses of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the customer address is default shipping.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the customer address is default billing.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created at of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated at of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string`","description":"The address name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The address 1 of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The address 2 of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The country code of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":trLine truncated
|
||||
<TypeList types={[{"name":"FindOrCreateCustomerOutputStepOutput","type":"[FindOrCreateCustomerOutputStepOutput](../../../../interfaces/core_flows.FindOrCreateCustomerOutputStepOutput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the customer found or created.","expandable":false,"children":[{"name":"customer","type":"`null` \\| [CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The customer found or created, if any.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"[CustomerAddressDTO](../../../../../customer/interfaces/customer.CustomerAddressDTO/page.mdx)[]","description":"The addresses of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the customer address is default shipping.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the customer address is default billing.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created at of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated at of the customer address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string`","description":"The address name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The address 1 of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The address 2 of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The country code of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the customer address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds cLine truncated
|
||||
+2
-2
@@ -31,8 +31,8 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"FindSalesChannelStepInput","type":"[FindSalesChannelStepInput](../../../../interfaces/core_flows.FindSalesChannelStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"salesChannelId","type":"`null` \\| `string`","description":"The ID of the sales channel to find.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findSalesChannelStep"/>
|
||||
<TypeList types={[{"name":"FindSalesChannelStepInput","type":"[FindSalesChannelStepInput](../../../../interfaces/core_flows.FindSalesChannelStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the sales channel to find.","expandable":false,"children":[{"name":"salesChannelId","type":"`null` \\| `string`","description":"The ID of the sales channel to find.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findSalesChannelStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"SalesChannelDTO","type":"[SalesChannelDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`null` \\| `string`","description":"The description of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_disabled","type":"`boolean`","description":"Whether the sales channel is disabled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"locations","type":"[SalesChannelLocationDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelLocationDTO/page.mdx)[]","description":"The locations of the sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"sales_channel_id","type":"`string`","description":"The associated sales channel's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel","type":"[SalesChannelDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelDTO/page.mdx)","description":"The associated sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`null` \\| `string`","description":"The description of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_disabled","type":"`boolean`","description":"Whether the sales channel is disabled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"locations","type":"[SalesChannelLocationDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelLocationDTO/page.mdx)[]","description":"The locations of the sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findSalesChannelStep"/>
|
||||
<TypeList types={[{"name":"SalesChannelDTO","type":"[SalesChannelDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelDTO/page.mdx)","optional":false,"defaultValue":"","description":"The sales channel details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`null` \\| `string`","description":"The description of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_disabled","type":"`boolean`","description":"Whether the sales channel is disabled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"locations","type":"[SalesChannelLocationDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelLocationDTO/page.mdx)[]","description":"The locations of the sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"sales_channel_id","type":"`string`","description":"The associated sales channel's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel","type":"[SalesChannelDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelDTO/page.mdx)","description":"The associated sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`null` \\| `string`","description":"The description of the sales channel.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_disabled","type":"`boolean`","description":"Whether the sales channel is disabled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"locations","type":"[SalesChannelLocationDTO](../../../../../sales_channel/interfaces/sales_channel.SalesChannelLocationDTO/page.mdx)[]","description":"The locations of the sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="findSalesChannelStep"/>
|
||||
+1
-1
@@ -34,7 +34,7 @@ const data = getActionsToComputeFromPromotionsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"GetActionsToComputeFromPromotionsStepInput","type":"[GetActionsToComputeFromPromotionsStepInput](../../../../interfaces/core_flows.GetActionsToComputeFromPromotionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","description":"The cart to compute the actions for.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"nameLine truncated
|
||||
<TypeList types={[{"name":"GetActionsToComputeFromPromotionsStepInput","type":"[GetActionsToComputeFromPromotionsStepInput](../../../../interfaces/core_flows.GetActionsToComputeFromPromotionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart and its applied promotions.","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","description":"The cart to compute the actions for.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -31,7 +31,7 @@ const data = getLineItemActionsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"GetLineItemActionsStepInput","type":"[GetLineItemActionsStepInput](../../../../interfaces/core_flows.GetLineItemActionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to create line items for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CreateLineItemForCartDTO](../../../../../cart/interfaces/cart.CreateLineItemForCartDTO/page.mdx)[]","description":"The line items to create or update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The quantity of the line item in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"unit_price","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The unit price of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The associated product's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type_id","type":"`string`","description":"The ID of type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The collection of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_id","type":"`string`","description":"The associated variant's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The option values of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":Line truncated
|
||||
<TypeList types={[{"name":"GetLineItemActionsStepInput","type":"[GetLineItemActionsStepInput](../../../../interfaces/core_flows.GetLineItemActionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line items to create or update.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to create line items for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CreateLineItemForCartDTO](../../../../../cart/interfaces/cart.CreateLineItemForCartDTO/page.mdx)[]","description":"The line items to create or update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The quantity of the line item in the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"unit_price","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The unit price of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The associated product's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type_id","type":"`string`","description":"The ID of type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The collection of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_id","type":"`string`","description":"The associated variant's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The option values of the associated variant.","optional":truLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ const data = getPromotionCodesToApply(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"GetPromotionCodesToApplyStepInput","type":"[GetPromotionCodesToApplyStepInput](../../../../interfaces/core_flows.GetPromotionCodesToApplyStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"`object`","description":"The cart containing items and shipping methods.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The cart's items and the promotion adjustments applied to them.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"adjustments","type":"`object`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shipping_methods","type":"`object`[]","description":"The cart's shipping methods and the promotion adjustments applied to them.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"adjustments","type":"`object`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]},{"name":"promo_codes","type":"`string`[]","description":"the promotion codes to be applied to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"action","type":"[ADD](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#add) \\| [REMOVE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#remove) \\| [REPLACE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#replace)","description":"Whether to add, remove, or replace promotion codes.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="getPromotionCodesToApply"/>
|
||||
<TypeList types={[{"name":"GetPromotionCodesToApplyStepInput","type":"[GetPromotionCodesToApplyStepInput](../../../../interfaces/core_flows.GetPromotionCodesToApplyStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the promotion codes to apply on a cart.","expandable":false,"children":[{"name":"cart","type":"`object`","description":"The cart containing items and shipping methods.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The cart's items and the promotion adjustments applied to them.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"adjustments","type":"`object`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shipping_methods","type":"`object`[]","description":"The cart's shipping methods and the promotion adjustments applied to them.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"adjustments","type":"`object`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]},{"name":"promo_codes","type":"`string`[]","description":"the promotion codes to be applied to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"action","type":"[ADD](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#add) \\| [REMOVE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#remove) \\| [REPLACE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#replace)","description":"Whether to add, remove, or replace promotion codes.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="getPromotionCodesToApply"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ const data = getVariantPriceSetsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"GetVariantPriceSetsStepInput","type":"[GetVariantPriceSetsStepInput](../../../../interfaces/core_flows.GetVariantPriceSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"variantIds","type":"`string`[]","description":"The IDs of the variants to get price sets for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"`Record<string, unknown>`","description":"The context to use when calculating the price sets.\n\nLearn more in [this documentation](https://docs.medusajs.com/resources/commerce-modules/product/guides/price#retrieve-calculated-price-for-a-context).","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="getVariantPriceSetsStep"/>
|
||||
<TypeList types={[{"name":"GetVariantPriceSetsStepInput","type":"[GetVariantPriceSetsStepInput](../../../../interfaces/core_flows.GetVariantPriceSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the variants to get price sets for.","expandable":false,"children":[{"name":"variantIds","type":"`string`[]","description":"The IDs of the variants to get price sets for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"`Record<string, unknown>`","description":"The context to use when calculating the price sets.\n\nLearn more in [this documentation](https://docs.medusajs.com/resources/commerce-modules/product/guides/price#retrieve-calculated-price-for-a-context).","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="getVariantPriceSetsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@ const data = getVariantsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"GetVariantsStepInput","type":"[GetVariantsStepInput](../../../../interfaces/core_flows.GetVariantsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"filter","type":"[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx)","description":"The filters to apply on retrieved product variants.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"q","type":"`string`","description":"Search through the title and different code attributes on the variant","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter product variants by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string` \\| `string`[]","description":"The SKUs to filter product variants by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string` \\| `string`[]","description":"Filter the product variants by their associated products' IDs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`Record<string, string>`","description":"Filter product variants by their associated options.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"q","type":"`string`","description":"Search through the title and different code attributes on the variant","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter product variants by.","optional":true,"defaultVaLine truncated
|
||||
<TypeList types={[{"name":"GetVariantsStepInput","type":"[GetVariantsStepInput](../../../../interfaces/core_flows.GetVariantsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the variants to retrieve.","expandable":false,"children":[{"name":"filter","type":"[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx)","description":"The filters to apply on retrieved product variants.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"q","type":"`string`","description":"Search through the title and different code attributes on the variant","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter product variants by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string` \\| `string`[]","description":"The SKUs to filter product variants by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string` \\| `string`[]","description":"Filter the product variants by their associated products' IDs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`Record<string, string>`","description":"Filter product variants by their associated options.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"([FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/page.mdx) \\| [BaseFilterable](../../../../../product/interfaces/product.BaseFilterable/page.mdx)<[FilterableProductVariantProps](../../../../../product/interfaces/product.FilterableProductVariantProps/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":"q","type":"`string`","description":"Search through the title and different code attributes on the variant","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter product Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+2
-2
@@ -30,8 +30,8 @@ const data = prepareAdjustmentsFromPromotionActionsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"PrepareAdjustmentsFromPromotionActionsStepInput","type":"[PrepareAdjustmentsFromPromotionActionsStepInput](../../../../interfaces/core_flows.PrepareAdjustmentsFromPromotionActionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"actions","type":"[ComputeActions](../../../../../promotion/types/promotion.ComputeActions/page.mdx)[]","description":"The actions computed by the Promotion Module.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"action","type":"`\"addItemAdjustment\"`","description":"The type of action.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../promotion/types/promotion.BigNumberInput/page.mdx)","description":"The amount to remove off the item's total.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../promotion/types/promotion.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"code","type":"`string`","description":"The promotion's code.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"adjustment_id","type":"`string`","description":"The associated adjustment's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_method_id","type":"`string`","description":"The associated shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The promotion's description.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="prepareAdjustmentsFromPromotionActionsStep"/>
|
||||
<TypeList types={[{"name":"PrepareAdjustmentsFromPromotionActionsStepInput","type":"[PrepareAdjustmentsFromPromotionActionsStepInput](../../../../interfaces/core_flows.PrepareAdjustmentsFromPromotionActionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the actions computed by the Promotion Module.","expandable":false,"children":[{"name":"actions","type":"[ComputeActions](../../../../../promotion/types/promotion.ComputeActions/page.mdx)[]","description":"The actions computed by the Promotion Module.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"action","type":"`\"addItemAdjustment\"`","description":"The type of action.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../promotion/types/promotion.BigNumberInput/page.mdx)","description":"The amount to remove off the item's total.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../promotion/types/promotion.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"code","type":"`string`","description":"The promotion's code.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"adjustment_id","type":"`string`","description":"The associated adjustment's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_method_id","type":"`string`","description":"The associated shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The promotion's description.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="prepareAdjustmentsFromPromotionActionsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"PrepareAdjustmentsFromPromotionActionsStepOutput","type":"[PrepareAdjustmentsFromPromotionActionsStepOutput](../../../../interfaces/core_flows.PrepareAdjustmentsFromPromotionActionsStepOutput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"lineItemAdjustmentsToCreate","type":"`object`[]","description":"The line item adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion code that computed the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The ID of the line item to adjust.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The ID of the applied promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"lineItemAdjustmentIdsToRemove","type":"`string`[]","description":"The line item adjustment IDs to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shippingMethodAdjustmentsToCreate","type":"`object`[]","description":"The shipping method adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion code that computed the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_method_id","type":"`string`","description":"The ID of the shipping method to adjust.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The ID of the applied promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shippingMethodAdjustmentIdsToRemove","type":"`string`[]","description":"The shipping method adjustment IDs to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"computedPromotionCodes","type":"`string`[]","description":"The promotion codes that were computed.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="prepareAdjustmentsFromPromotionActionsStep"/>
|
||||
<TypeList types={[{"name":"PrepareAdjustmentsFromPromotionActionsStepOutput","type":"[PrepareAdjustmentsFromPromotionActionsStepOutput](../../../../interfaces/core_flows.PrepareAdjustmentsFromPromotionActionsStepOutput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the adjustments to create and remove.","expandable":false,"children":[{"name":"lineItemAdjustmentsToCreate","type":"`object`[]","description":"The line item adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion code that computed the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The ID of the line item to adjust.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The ID of the applied promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"lineItemAdjustmentIdsToRemove","type":"`string`[]","description":"The line item adjustment IDs to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shippingMethodAdjustmentsToCreate","type":"`object`[]","description":"The shipping method adjustments to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion code that computed the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_method_id","type":"`string`","description":"The ID of the shipping method to adjust.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The ID of the applied promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"shippingMethodAdjustmentIdsToRemove","type":"`string`[]","description":"The shipping method adjustment IDs to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"computedPromotionCodes","type":"`string`[]","description":"The promotion codes that were computed.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="prepareAdjustmentsFromPromotionActionsStep"/>
|
||||
+1
-1
@@ -33,4 +33,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RemoveLineItemAdjustmentsStepInput","type":"[RemoveLineItemAdjustmentsStepInput](../../../../interfaces/core_flows.RemoveLineItemAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"lineItemAdjustmentIdsToRemove","type":"`string`[]","description":"The IDs of the line item adjustments to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeLineItemAdjustmentsStep"/>
|
||||
<TypeList types={[{"name":"RemoveLineItemAdjustmentsStepInput","type":"[RemoveLineItemAdjustmentsStepInput](../../../../interfaces/core_flows.RemoveLineItemAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line item adjustments to remove.","expandable":false,"children":[{"name":"lineItemAdjustmentIdsToRemove","type":"`string`[]","description":"The IDs of the line item adjustments to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeLineItemAdjustmentsStep"/>
|
||||
+1
-1
@@ -33,4 +33,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RemoveShippingMethodAdjustmentsStepInput","type":"[RemoveShippingMethodAdjustmentsStepInput](../../../../interfaces/core_flows.RemoveShippingMethodAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"shippingMethodAdjustmentIdsToRemove","type":"`string`[]","description":"The IDs of the shipping method adjustments to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeShippingMethodAdjustmentsStep"/>
|
||||
<TypeList types={[{"name":"RemoveShippingMethodAdjustmentsStepInput","type":"[RemoveShippingMethodAdjustmentsStepInput](../../../../interfaces/core_flows.RemoveShippingMethodAdjustmentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping method adjustments to remove.","expandable":false,"children":[{"name":"shippingMethodAdjustmentIdsToRemove","type":"`string`[]","description":"The IDs of the shipping method adjustments to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeShippingMethodAdjustmentsStep"/>
|
||||
+1
-1
@@ -33,7 +33,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RemoveShippingMethodFromCartStepInput","type":"[RemoveShippingMethodFromCartStepInput](../../../../interfaces/core_flows.RemoveShippingMethodFromCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"shipping_method_ids","type":"`string`[]","description":"The IDs of the shipping methods to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeShippingMethodFromCartStep"/>
|
||||
<TypeList types={[{"name":"RemoveShippingMethodFromCartStepInput","type":"[RemoveShippingMethodFromCartStepInput](../../../../interfaces/core_flows.RemoveShippingMethodFromCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping methods to remove.","expandable":false,"children":[{"name":"shipping_method_ids","type":"`string`[]","description":"The IDs of the shipping methods to remove.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeShippingMethodFromCartStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ const data = reserveInventoryStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ReserveVariantInventoryStepInput","type":"[ReserveVariantInventoryStepInput](../../../../interfaces/core_flows.ReserveVariantInventoryStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the inventory item to reserve quantities from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"required_quantity","type":"`number`","description":"The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the\nvalue set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"allow_backorder","type":"`boolean`","description":"Whether the variant can be ordered even if it's out of stock.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity to reserve.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location_ids","type":"`string`[]","description":"The IDs of stock locations to reserve the item's quantity in.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"The ID for the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="reserveInventoryStep"/>
|
||||
<TypeList types={[{"name":"ReserveVariantInventoryStepInput","type":"[ReserveVariantInventoryStepInput](../../../../interfaces/core_flows.ReserveVariantInventoryStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the items and their quantity to reserve.","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the inventory item to reserve quantities from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"required_quantity","type":"`number`","description":"The number of units a single quantity is equivalent to. For example, if a customer orders one quantity of the variant, Medusa checks the availability of the quantity multiplied by the\nvalue set for `required_quantity`. When the customer orders the quantity, Medusa reserves the ordered quantity multiplied by the value set for `required_quantity`.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"allow_backorder","type":"`boolean`","description":"Whether the variant can be ordered even if it's out of stock.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity to reserve.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location_ids","type":"`string`[]","description":"The IDs of stock locations to reserve the item's quantity in.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"The ID for the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="reserveInventoryStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+3
-3
@@ -19,7 +19,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = retrieveCartStep({
|
||||
"id": "id_8g7NNTcCjl4BRoAM"
|
||||
"id": "id_eu6JXpbdY7"
|
||||
})
|
||||
}
|
||||
)
|
||||
@@ -28,8 +28,8 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RetrieveCartStepInput","type":"[RetrieveCartStepInput](../../../../interfaces/core_flows.RetrieveCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to retrieve.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"config","type":"[FindConfig](../../../../../medusa/interfaces/medusa.FindConfig/page.mdx)<[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)>","description":"An object that is used to configure how an entity is retrieved from the database. It accepts as a typed parameter an \n\n`Entity`\n\n class,\nwhich provides correct typing of field names in its properties.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"select","type":"(`string` \\| keyof Entity)[]","description":"An array of strings, each being attribute names of the entity to retrieve in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"skip","type":"`null` \\| `number`","description":"A number indicating the number of records to skip before retrieving the results.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"take","type":"`null` \\| `number`","description":"A number indicating the number of records to return in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"relations","type":"`string`[]","description":"An array of strings, each being relation names of the entity to retrieve in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"order","type":"[FindConfigOrder](../../../../../medusa/types/medusa.FindConfigOrder/page.mdx)","description":"An object used to specify how to sort the returned records. Its keys are the names of attributes of the entity, and a key's value can either be `ASC`\nto sort retrieved records in an ascending order, or `DESC` to sort retrieved records in a descending order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"withDeleted","type":"`boolean`","description":"A boolean indicating whether deleted records should also be retrieved as part of the result. This only works if the entity extends the\n`SoftDeletableEntity` class.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Enable ORM specific defined filters","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`Record<string, any>`","description":"Enable ORM specific defined options","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="retrieveCartStep"/>
|
||||
<TypeList types={[{"name":"RetrieveCartStepInput","type":"[RetrieveCartStepInput](../../../../interfaces/core_flows.RetrieveCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart to retrieve.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to retrieve.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"config","type":"[FindConfig](../../../../../medusa/interfaces/medusa.FindConfig/page.mdx)<[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)>","description":"An object that is used to configure how an entity is retrieved from the database. It accepts as a typed parameter an \n\n`Entity`\n\n class,\nwhich provides correct typing of field names in its properties.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"select","type":"(`string` \\| keyof Entity)[]","description":"An array of strings, each being attribute names of the entity to retrieve in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"skip","type":"`null` \\| `number`","description":"A number indicating the number of records to skip before retrieving the results.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"take","type":"`null` \\| `number`","description":"A number indicating the number of records to return in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"relations","type":"`string`[]","description":"An array of strings, each being relation names of the entity to retrieve in the result.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"order","type":"[FindConfigOrder](../../../../../medusa/types/medusa.FindConfigOrder/page.mdx)","description":"An object used to specify how to sort the returned records. Its keys are the names of attributes of the entity, and a key's value can either be `ASC`\nto sort retrieved records in an ascending order, or `DESC` to sort retrieved records in a descending order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"withDeleted","type":"`boolean`","description":"A boolean indicating whether deleted records should also be retrieved as part of the result. This only works if the entity extends the\n`SoftDeletableEntity` class.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"filters","type":"`Record<string, any>`","description":"Enable ORM specific defined filters","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`Record<string, any>`","description":"Enable ORM specific defined options","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="retrieveCartStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"CartDTO","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","optional":false,"defaultValue":"","description":"","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":Line truncated
|
||||
<TypeList types={[{"name":"CartDTO","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","optional":false,"defaultValue":"","description":"The cart details.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"chLine truncated
|
||||
+1
-1
@@ -46,4 +46,4 @@ const data = setTaxLinesForItemsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"SetTaxLinesForItemsStepInput","type":"[SetTaxLinesForItemsStepInput](../../../../interfaces/core_flows.SetTaxLinesForItemsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/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":"payment_collection","type":"[PaymentCollectionDTO](../../../../../payment/interfaces/payment.PaymentCollectionDTO/page.mdx)","description":"The payment collection details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The ISO 3 character currency code of the payment sessions and payments associated with payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The total amount to be authorized and captured.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PaymentCollectionStatus](../../../../../payment/types/payment.PaymentCollectionStatus/page.mdx)","description":"The status of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../payment/interfaces/payment.PaymentProviderDTO/page.mdx)[]","description":"The payment provider used to process the associated payment sessions and payments.","optional":false,"defaultValue":"","expandable":true,"children":[]},{"name":"authorized_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount authorized within the associated payment sessions.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"refunded_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount refunded within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"captured_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount captured within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"completed_at","type":"`string` \\| `Date`","description":"When the payment collection was completed.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"When the payment collection was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"When the payment collection was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_sessions","type":"[PaymentSessionDTO](../../../../../payment/interfaces/payment.PaymentSessionDTO/page.mdx)[]","description":"The associated payment sessions.","optional":true,"defaultValue":"","expandable":true,"children":[]},{"name":"payments","type":"[PaymentDTO](../../../../../payment/interfaces/payment.PaymentDTO/page.mdx)[]","description":"The associated payments.","optional":true,"defaultValue":"","expandable":true,"children":[]}]},{"name":"customer","type":"[CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":false,"defaultValue":"","expandable":false,"childrLine truncated
|
||||
<TypeList types={[{"name":"SetTaxLinesForItemsStepInput","type":"[SetTaxLinesForItemsStepInput](../../../../interfaces/core_flows.SetTaxLinesForItemsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the tax lines to set in a cart.","expandable":false,"children":[{"name":"cart","type":"[CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/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":"payment_collection","type":"[PaymentCollectionDTO](../../../../../payment/interfaces/payment.PaymentCollectionDTO/page.mdx)","description":"The payment collection details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The ISO 3 character currency code of the payment sessions and payments associated with payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The total amount to be authorized and captured.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PaymentCollectionStatus](../../../../../payment/types/payment.PaymentCollectionStatus/page.mdx)","description":"The status of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../payment/interfaces/payment.PaymentProviderDTO/page.mdx)[]","description":"The payment provider used to process the associated payment sessions and payments.","optional":false,"defaultValue":"","expandable":true,"children":[]},{"name":"authorized_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount authorized within the associated payment sessions.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"refunded_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount refunded within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"captured_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount captured within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"completed_at","type":"`string` \\| `Date`","description":"When the payment collection was completed.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"When the payment collection was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"When the payment collection was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_sessions","type":"[PaymentSessionDTO](../../../../../payment/interfaces/payment.PaymentSessionDTO/page.mdx)[]","description":"The associated payment sessions.","optional":true,"defaultValue":"","expandable":true,"children":[]},{"name":"payments","type":"[PaymentDTO](../../../../../payment/interfaces/payment.PaymentDTO/page.mdx)[]","description":"The associated payments.","optional":true,"defaultValue":"","expandable":true,"children":[]}]},{"name":"customer","type":"[CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":falsLine truncated
|
||||
+2
-2
@@ -24,7 +24,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = updateCartPromotionsStep({
|
||||
"id": "id_2j8HGkLk4W5B3mBmY"
|
||||
"id": "id_I7vWXI62j0UrZ"
|
||||
})
|
||||
}
|
||||
)
|
||||
@@ -33,4 +33,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCartPromotionStepInput","type":"[UpdateCartPromotionStepInput](../../../../interfaces/core_flows.UpdateCartPromotionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to update promotions for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"The promotion codes to apply on the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"action","type":"[ADD](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#add) \\| [REMOVE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#remove) \\| [REPLACE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#replace)","description":"Whether to add, remove, or replace promotion codes.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateCartPromotionsStep"/>
|
||||
<TypeList types={[{"name":"UpdateCartPromotionStepInput","type":"[UpdateCartPromotionStepInput](../../../../interfaces/core_flows.UpdateCartPromotionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the promotion codes to apply on a cart.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to update promotions for.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"The promotion codes to apply on the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"action","type":"[ADD](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#add) \\| [REMOVE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#remove) \\| [REPLACE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#replace)","description":"Whether to add, remove, or replace promotion codes.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateCartPromotionsStep"/>
|
||||
+1
-1
@@ -25,7 +25,7 @@ const data = updateCartsStep([{
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCartsStepInput","type":"[UpdateCartsStepInput](../../../../types/core_flows.UpdateCartsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to update.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"An array of promotional codes applied on the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"region_id","type":"`string`","description":"The ID of the cart's region.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`null` \\| `string`","description":"The ID of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel_id","type":"`null` \\| `string`","description":"The ID of the cart's sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email address of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code for the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Custom key-value pairs of data related to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's shipping address. You can either update the cart's existing shipping address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"billing_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's billing address. You can either update the cart's existing billing address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`stringLine truncated
|
||||
<TypeList types={[{"name":"UpdateCartsStepInput","type":"[UpdateCartsStepInput](../../../../types/core_flows.UpdateCartsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the carts to update.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to update.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"An array of promotional codes applied on the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"region_id","type":"`string`","description":"The ID of the cart's region.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`null` \\| `string`","description":"The ID of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel_id","type":"`null` \\| `string`","description":"The ID of the cart's sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email address of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code for the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Custom key-value pairs of data related to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's shipping address. You can either update the cart's existing shipping address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"billing_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's billing address. You can either update the cart's existing billing address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ const data = updateLineItemsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateLineItemsStepInput","type":"[UpdateLineItemsStepInput](../../../../interfaces/core_flows.UpdateLineItemsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart that the line items belong to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[UpdateLineItemWithSelectorDTO](../../../../../cart/interfaces/cart.UpdateLineItemWithSelectorDTO/page.mdx)[]","description":"The line items to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"Partial<[CartLineItemDTO](../../../../../cart/interfaces/cart.CartLineItemDTO/page.mdx)>","description":"Filters to specify which line items to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The discount total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The discount tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_subtotal","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_tax_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_subtotal","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_tax_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_total","type":"[BigNumberRawValue](../../../Line truncated
|
||||
<TypeList types={[{"name":"UpdateLineItemsStepInput","type":"[UpdateLineItemsStepInput](../../../../interfaces/core_flows.UpdateLineItemsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line items to update.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart that the line items belong to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[UpdateLineItemWithSelectorDTO](../../../../../cart/interfaces/cart.UpdateLineItemWithSelectorDTO/page.mdx)[]","description":"The line items to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"Partial<[CartLineItemDTO](../../../../../cart/interfaces/cart.CartLineItemDTO/page.mdx)>","description":"Filters to specify which line items to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"original_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The discount total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"discount_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The discount tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_subtotal","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_original_tax_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw original tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_subtotal","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item subtotal of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_item_tax_total","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"The raw item tax total of the cart line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw_totaLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ const data = updateOrderShippingMethodsStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateShippingMethodsStepInput","type":"[UpdateShippingMethodsStepInput](../../../../types/core_flows.UpdateShippingMethodsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"is_tax_inclusive","type":"`boolean`","description":"The tax inclusivity setting of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The data of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_lines","type":"[CreateTaxLineDTO](../../../../../cart/interfaces/cart.CreateTaxLineDTO/page.mdx)[] \\| [UpdateTaxLineDTO](../../../../../cart/interfaces/cart.UpdateTaxLineDTO/page.mdx)[]","description":"The tax lines of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rate","type":"`number`","description":"The rate of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"The ID of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the tax line.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_rate_id","type":"`string`","description":"The associated tax rate's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"adjustments","type":"[CreateAdjustmentDTO](../../../../../cart/interfaces/cart.CreateAdjustmentDTO/page.mdx)[] \\| [UpdateAdjustmentDTO](../../../../../cart/interfaces/cart.UpdateAdjustmentDTO/page.mdx)[]","description":"The adjustments of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"id","type":"`string`","description":"The ID of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"Line truncated
|
||||
<TypeList types={[{"name":"UpdateShippingMethodsStepInput","type":"[UpdateShippingMethodsStepInput](../../../../types/core_flows.UpdateShippingMethodsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping methods to update.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"is_tax_inclusive","type":"`boolean`","description":"The tax inclusivity setting of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The data of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_lines","type":"[CreateTaxLineDTO](../../../../../cart/interfaces/cart.CreateTaxLineDTO/page.mdx)[] \\| [UpdateTaxLineDTO](../../../../../cart/interfaces/cart.UpdateTaxLineDTO/page.mdx)[]","description":"The tax lines of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rate","type":"`number`","description":"The rate of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string`","description":"The ID of the tax line.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the tax line.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"tax_rate_id","type":"`string`","description":"The associated tax rate's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated provider's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The associated item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"adjustments","type":"[CreateAdjustmentDTO](../../../../../cart/interfaces/cart.CreateAdjustmentDTO/page.mdx)[] \\| [UpdateAdjustmentDTO](../../../../../cart/interfaces/cart.UpdateAdjustmentDTO/page.mdx)[]","description":"The adjustments of the shipping method.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The code of the promotion that lead to\nthis adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The amount to adjust the original amount with.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"id","type":"`string`","description":"The ID of the adjustment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The description of the adjustment.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"promotion_id","type":"`string`","description":"The associated promotion's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -70,7 +70,7 @@ const data = validateAndReturnShippingMethodsDataStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateShippingMethodsDataInput","type":"[ValidateShippingMethodsDataInput](../../../../types/core_flows.ValidateShippingMethodsDataInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The fulfillment provider ID that associated with the shipping option\nthat the method was created from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"option_data","type":"`Record<string, unknown>`","description":"The `data` property of the shipping option that the shipping method was \ncreated from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"method_data","type":"`Record<string, unknown>`","description":"The `data` property of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"[ValidateFulfillmentDataContext](../../../../../fulfillment/types/fulfillment.ValidateFulfillmentDataContext/page.mdx)","description":"The context to validate the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"id\"`]","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"shipping_address\"`]","description":"The cart's shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"items\"`] & `object`","description":"The cart's items","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"variant","type":"`object`","description":"The item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"product","type":"`object`","description":"The item's product.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"from_location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"Details about the location that items are being shipped from.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_sets","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)[]","description":"Fulfillment sets for the location","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"The creation date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"The update date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`string` \\| `Date` \\| `null`","description":"The deletion date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address","type":"[StockLocationAddressDTO](../../../../../fulfillment/types/fulfillment.StockLocationAddressDTO/page.mdx)","description":"The address of the stock location.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateAndReturnShippingMethodsDataStep"/>
|
||||
<TypeList types={[{"name":"ValidateShippingMethodsDataInput","type":"[ValidateShippingMethodsDataInput](../../../../types/core_flows.ValidateShippingMethodsDataInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping methods to validate.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The shipping method's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The fulfillment provider ID that associated with the shipping option\nthat the method was created from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"option_data","type":"`Record<string, unknown>`","description":"The `data` property of the shipping option that the shipping method was \ncreated from.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"method_data","type":"`Record<string, unknown>`","description":"The `data` property of the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"[ValidateFulfillmentDataContext](../../../../../fulfillment/types/fulfillment.ValidateFulfillmentDataContext/page.mdx)","description":"The context to validate the shipping method.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"id\"`]","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"shipping_address\"`]","description":"The cart's shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"items\"`] & `object`","description":"The cart's items","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"variant","type":"`object`","description":"The item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"product","type":"`object`","description":"The item's product.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"from_location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"Details about the location that items are being shipped from.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_sets","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)[]","description":"Fulfillment sets for the location","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"The creation date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"The update date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`string` \\| `Date` \\| `null`","description":"The deletion date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address","type":"[StockLocationAddressDTO](../../../../../fulfillment/types/fulfillment.StockLocationAddressDTO/page.mdx)","description":"The address of the stock location.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateAndReturnShippingMethodsDataStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -32,7 +32,7 @@ const data = validateCartPaymentsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateCartPaymentsStepInput","type":"[ValidateCartPaymentsStepInput](../../../../interfaces/core_flows.ValidateCartPaymentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/page.mdx)","description":"The cart to validate payment sessions for.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_collection","type":"[PaymentCollectionDTO](../../../../../payment/interfaces/payment.PaymentCollectionDTO/page.mdx)","description":"The payment collection details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The ISO 3 character currency code of the payment sessions and payments associated with payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The total amount to be authorized and captured.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PaymentCollectionStatus](../../../../../payment/types/payment.PaymentCollectionStatus/page.mdx)","description":"The status of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../payment/interfaces/payment.PaymentProviderDTO/page.mdx)[]","description":"The payment provider used to process the associated payment sessions and payments.","optional":false,"defaultValue":"","expandable":true,"children":[]},{"name":"authorized_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount authorized within the associated payment sessions.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"refunded_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount refunded within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"captured_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount captured within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"completed_at","type":"`string` \\| `Date`","description":"When the payment collection was completed.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"When the payment collection was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"When the payment collection was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_sessions","type":"[PaymentSessionDTO](../../../../../payment/interfaces/payment.PaymentSessionDTO/page.mdx)[]","description":"The associated payment sessions.","optional":true,"defaultValue":"","expandable":true,"children":[]},{"name":"payments","type":"[PaymentDTO](../../../../../payment/interfaces/payment.PaymentDTO/page.mdx)[]","description":"The associated payments.","optional":true,"defaultValue":"","expandable":true,"children":[]}]},{"name":"customer","type":"[CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":false,"defaultValue":"",Line truncated
|
||||
<TypeList types={[{"name":"ValidateCartPaymentsStepInput","type":"[ValidateCartPaymentsStepInput](../../../../interfaces/core_flows.ValidateCartPaymentsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The cart's details.","expandable":false,"children":[{"name":"cart","type":"[CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/page.mdx)","description":"The cart to validate payment sessions for.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_collection","type":"[PaymentCollectionDTO](../../../../../payment/interfaces/payment.PaymentCollectionDTO/page.mdx)","description":"The payment collection details.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The ISO 3 character currency code of the payment sessions and payments associated with payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The total amount to be authorized and captured.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PaymentCollectionStatus](../../../../../payment/types/payment.PaymentCollectionStatus/page.mdx)","description":"The status of the payment collection.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_providers","type":"[PaymentProviderDTO](../../../../../payment/interfaces/payment.PaymentProviderDTO/page.mdx)[]","description":"The payment provider used to process the associated payment sessions and payments.","optional":false,"defaultValue":"","expandable":true,"children":[]},{"name":"authorized_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount authorized within the associated payment sessions.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"refunded_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount refunded within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"captured_amount","type":"[BigNumberValue](../../../../../payment/types/payment.BigNumberValue/page.mdx)","description":"The amount captured within the associated payments.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"completed_at","type":"`string` \\| `Date`","description":"When the payment collection was completed.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"When the payment collection was created.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"When the payment collection was updated.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"payment_sessions","type":"[PaymentSessionDTO](../../../../../payment/interfaces/payment.PaymentSessionDTO/page.mdx)[]","description":"The associated payment sessions.","optional":true,"defaultValue":"","expandable":true,"children":[]},{"name":"payments","type":"[PaymentDTO](../../../../../payment/interfaces/payment.PaymentDTO/page.mdx)[]","description":"The associated payments.","optional":true,"defaultValue":"","expandable":true,"children":[]}]},{"name":"customer","type":"[CustomerDTO](../../../../../customer/interfaces/customer.CustomerDTO/page.mdx)","description":"The cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"A flag indicating if customer has an account or not.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_billing_address_id","type":"`null` \\| `string`","description":"The associated default billing address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"default_shipping_address_id","type":"`null` \\| `string`","description":"The associated default shipping address's ID.","optional":falseLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,4 +34,4 @@ const data = validateCartShippingOptionsPriceStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateCartShippingOptionsPriceInput","type":"[ValidateCartShippingOptionsPriceInput](../../../../types/core_flows.ValidateCartShippingOptionsPriceInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"shippingOptions","type":"`any`[]","description":"The shipping option's details. Should have a `calculated_price.calculated_amount`\nto be considered valid.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateCartShippingOptionsPriceStep"/>
|
||||
<TypeList types={[{"name":"ValidateCartShippingOptionsPriceInput","type":"[ValidateCartShippingOptionsPriceInput](../../../../types/core_flows.ValidateCartShippingOptionsPriceInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the shipping options to validate.","expandable":false,"children":[{"name":"shippingOptions","type":"`any`[]","description":"The shipping option's details. Should have a `calculated_price.calculated_amount`\nto be considered valid.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateCartShippingOptionsPriceStep"/>
|
||||
+1
-1
@@ -29,4 +29,4 @@ const data = validateCartShippingOptionsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateCartShippingOptionsStepInput","type":"[ValidateCartShippingOptionsStepInput](../../../../interfaces/core_flows.ValidateCartShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","description":"The cart to validate shipping options for.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric",Line truncated
|
||||
<TypeList types={[{"name":"ValidateCartShippingOptionsStepInput","type":"[ValidateCartShippingOptionsStepInput](../../../../interfaces/core_flows.ValidateCartShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart and its shipping options context.","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx)","description":"The cart to validate shipping options for.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultVaLine truncated
|
||||
+1
-1
@@ -32,4 +32,4 @@ const data = validateCartStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateCartStepInput","type":"[ValidateCartStepInput](../../../../interfaces/core_flows.ValidateCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx) \\| [CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/page.mdx)","description":"The cart to validate.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children"Line truncated
|
||||
<TypeList types={[{"name":"ValidateCartStepInput","type":"[ValidateCartStepInput](../../../../interfaces/core_flows.ValidateCartStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart to validate.","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx) \\| [CartWorkflowDTO](../../../../../types/interfaces/types.CartWorkflowDTO/page.mdx)","description":"The cart to validate.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultValLine truncated
|
||||
+1
-1
@@ -32,4 +32,4 @@ const data = validateLineItemPricesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateLineItemPricesStepInput","type":"[ValidateLineItemPricesStepInput](../../../../interfaces/core_flows.ValidateLineItemPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The line items to validate.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"unit_price","type":"`null` \\| `number`","description":"The price of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateLineItemPricesStep"/>
|
||||
<TypeList types={[{"name":"ValidateLineItemPricesStepInput","type":"[ValidateLineItemPricesStepInput](../../../../interfaces/core_flows.ValidateLineItemPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line items to validate.","expandable":false,"children":[{"name":"items","type":"`object`[]","description":"The line items to validate.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"unit_price","type":"`null` \\| `number`","description":"The price of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateLineItemPricesStep"/>
|
||||
+1
-1
@@ -34,4 +34,4 @@ const data = validateVariantPricesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateVariantPricesStepInput","type":"[ValidateVariantPricesStepInput](../../../../interfaces/core_flows.ValidateVariantPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"variants","type":"`object`[]","description":"The variants to validate.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"calculated_price","type":"`object`","description":"The calculated price of the variant.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"calculated_amount","type":"`null` \\| [BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The calculated amount of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateVariantPricesStep"/>
|
||||
<TypeList types={[{"name":"ValidateVariantPricesStepInput","type":"[ValidateVariantPricesStepInput](../../../../interfaces/core_flows.ValidateVariantPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the variants to validate.","expandable":false,"children":[{"name":"variants","type":"`object`[]","description":"The variants to validate.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"calculated_price","type":"`object`","description":"The calculated price of the variant.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"calculated_amount","type":"`null` \\| [BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The calculated amount of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateVariantPricesStep"/>
|
||||
+1
-5
@@ -176,16 +176,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"addShippingMethodToCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"step","name":"validateCartShippingOptionsStep","description":"This step validates shipping options to ensure they can be applied on a cart.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartShippingOptionsStep/page.mdx","depth":4},{"type":"workflow","name":"listShippingOptionsForCartWithPricingWorkflow","description":"This workflow lists shipping options that can be used during checkout for a cart. It also retrieves the prices\nof these shipping options, including calculated prices that may be retrieved from third-party providers.\n\nThis workflow is executed in other cart-related workflows, such as [addShippingMethodToCartWorkflow](./page.mdx) to retrieve the\nprice of the shipping method being added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to retrieve the shipping options of a cart and their prices \nin your custom flows.","link":"../core_flows.Cart.Workflows_Cart.listShippingOptionsForCartWithPricingWorkflow/page.mdx","depth":5},{"type":"step","name":"validateCartShippingOptionsPriceStep","description":"This step validates shipping options to ensure they have a price.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartShippingOptionsPriceStep/page.mdx","depth":6},{"type":"step","name":"validateAndReturnShippingMethodsDataStep","description":"This step validates shipping options to ensure they can be applied on a cart.\nThe step either returns the validated data or void.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateAndReturnShippingMethodsDataStep/page.mdx","depth":7},{"type":"step","name":"removeShippingMethodFromCartStep","description":"This step removes shipping methods from a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.removeShippingMethodFromCartStep/page.mdx","depth":8},{"type":"step","name":"addShippingMethodToCartStep","description":"This step adds shipping methods to a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.addShippingMethodToCartStep/page.mdx","depth":8},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":8},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"This workflow refreshes a cart to ensure its prices, promotion codes, taxes, and other details are applied correctly. It's useful\nafter making a chnge to a cart, such as after adding an item to the cart or adding a promotion code.\n\nThis workflow is used by other cart-related workflows, such as the [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx) after an item\nis added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart after making updates to it in your\ncustom flows.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":9}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"addShippingMethodToCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"step","name":"validateCartShippingOptionsStep","description":"This step validates shipping options to ensure they can be applied on a cart.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartShippingOptionsStep/page.mdx","depth":4},{"type":"workflow","name":"listShippingOptionsForCartWithPricingWorkflow","description":"List a cart's shipping options with prices.","link":"../core_flows.Cart.Workflows_Cart.listShippingOptionsForCartWithPricingWorkflow/page.mdx","depth":5},{"type":"step","name":"validateCartShippingOptionsPriceStep","description":"This step validates shipping options to ensure they have a price.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartShippingOptionsPriceStep/page.mdx","depth":6},{"type":"step","name":"validateAndReturnShippingMethodsDataStep","description":"This step validates shipping options to ensure they can be applied on a cart.\nThe step either returns the validated data or void.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateAndReturnShippingMethodsDataStep/page.mdx","depth":7},{"type":"step","name":"removeShippingMethodFromCartStep","description":"This step removes shipping methods from a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.removeShippingMethodFromCartStep/page.mdx","depth":8},{"type":"step","name":"addShippingMethodToCartStep","description":"This step adds shipping methods to a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.addShippingMethodToCartStep/page.mdx","depth":8},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":8},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"Refresh a cart's details after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":9}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"AddShippingMethodToCartWorkflowInput","type":"[AddShippingMethodToCartWorkflowInput](../../../../interfaces/core_flows.AddShippingMethodToCartWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to add a shipping method to a cart.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The ID of the cart to add the shipping method to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`object`[]","description":"The shipping options to create the shipping methods from and add to the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"Custom data useful for the fulfillment provider processing the shipping option or method.\n\nLearn more in [this documentation](https://docs.medusajs.com/resources/commerce-modules/fulfillment/shipping-option#data-property).","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="addShippingMethodToCartWorkflow"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="addShippingMethodToCartWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-5
@@ -178,16 +178,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"addToCartWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"4","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":4}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":5},{"type":"step","name":"validateLineItemPricesStep","description":"This step validates the specified line item objects to ensure they have prices.\nIf an item doesn't have a price, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateLineItemPricesStep/page.mdx","depth":6},{"type":"step","name":"getLineItemActionsStep","description":"This step returns lists of cart line items to create or update based on the\nprovided input.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.getLineItemActionsStep/page.mdx","depth":7},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"This workflow validates that product variants are in-stock at the specified sales channel, before adding them or updating their quantity in the cart. If a variant doesn't have sufficient quantity in-stock,\nthe workflow throws an error. If all variants have sufficient inventory, the workflow returns the cart's items with their inventory details.\n\nThis workflow is useful when confirming that a product variant has sufficient quantity to be added to or updated in the cart. It's executed\nby other cart-related workflows, such as [addToCartWorkflow](./page.mdx), to confirm that a product variant can be added to the cart at the specified quantity.\n\n:::note\n\nLearn more about the links between the product variant and sales channels and inventory items in [this documentation](https://docs.medusajs.com/resources/commerce-modules/product/links-to-other-modules).\n\n:::\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to check whether a product variant has enough inventory quantity before adding them to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":8},{"type":"step","name":"createLineItemsStep","description":"This step creates line item in a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.createLineItemsStep/page.mdx","depth":9},{"type":"step","name":"updateLineItemsStep","description":"This step updates a cart's line items.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateLineItemsStep/page.mdx","depth":9},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"This workflow refreshes a cart to ensure its prices, promotion codes, taxes, and other details are applied correctly. It's useful\nafter making a chnge to a cart, such as after adding an item to the cart or adding a promotion code.\n\nThis workflow is used by other cart-related workflows, such as the [addToCartWorkflow](./page.mdx) after an item\nis added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart after making updates to it in your\ncustom flows.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":10},{"type":"step","name":"emitEventStep"Line truncated
|
||||
<WorkflowDiagram workflow={{"name":"addToCartWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"4","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":4}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":5},{"type":"step","name":"validateLineItemPricesStep","description":"This step validates the specified line item objects to ensure they have prices.\nIf an item doesn't have a price, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateLineItemPricesStep/page.mdx","depth":6},{"type":"step","name":"getLineItemActionsStep","description":"This step returns lists of cart line items to create or update based on the\nprovided input.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.getLineItemActionsStep/page.mdx","depth":7},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"Validate that a variant is in-stock before adding to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":8},{"type":"step","name":"createLineItemsStep","description":"This step creates line item in a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.createLineItemsStep/page.mdx","depth":9},{"type":"step","name":"updateLineItemsStep","description":"This step updates a cart's line items.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateLineItemsStep/page.mdx","depth":9},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"Refresh a cart's details after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":10},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":11}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"AddToCartWorkflowInputDTO","type":"[AddToCartWorkflowInputDTO](../../../../../types/interfaces/types.AddToCartWorkflowInputDTO/page.mdx)","optional":false,"defaultValue":"","description":"The details of adding items to the cart.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The ID of the cart to add items to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CreateCartCreateLineItemDTO](../../../../../types/interfaces/types.CreateCartCreateLineItemDTO/page.mdx)[]","description":"The items to add to the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"quantity","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"variant_id","type":"`string`","description":"The ID of the variant to be added to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"title","type":"`string`","description":"The title of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail URL of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The ID of the product whose variant is being added to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The ID of the associated product's type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The ID of the associated product's collection.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The associated variant's values for the product's options.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"requires_shipping","type":"`boolean`","description":"Whether the line item requires shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_discountable","type":"`boolean`","description":"Whether the line item is discountable.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_tax_inclusive","type":"`boolean`","description":"Whether the line item's price is tax inclusive. Learn more in \n[this documentation](https://docs.medusajs.com/resources/commerce-modules/pricing/tax-inclusive-pricing)","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_giftcard","type":"`boolean`","description":"Whether the line item is a gift card.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"compare_at_unit_price","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The original price of the item before a promotion or sale.",Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="addToCartWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-1
@@ -173,7 +173,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"createCartWorkflow","steps":[{"type":"step","name":"findSalesChannelStep","description":"This step either retrieves a sales channel either using the ID provided as an input, or, if no ID\nis provided, the default sales channel of the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findSalesChannelStep/page.mdx","depth":1},{"type":"step","name":"findOneOrAnyRegionStep","description":"This step retrieves a region either by the provided ID or the first region in the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOneOrAnyRegionStep/page.mdx","depth":1},{"type":"step","name":"findOrCreateCustomerStep","description":"This step either finds a customer matching the specified ID, or finds / create a customer\nmatching the specified email. If both ID and email are provided, ID takes precedence.\nIf the customer is a guest, the email is updated to the provided email.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOrCreateCustomerStep/page.mdx","depth":1},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"2","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":2}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":3},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"This workflow validates that product variants are in-stock at the specified sales channel, before adding them or updating their quantity in the cart. If a variant doesn't have sufficient quantity in-stock,\nthe workflow throws an error. If all variants have sufficient inventory, the workflow returns the cart's items with their inventory details.\n\nThis workflow is useful when confirming that a product variant has sufficient quantity to be added to or updated in the cart. It's executed\nby other cart-related workflows, such as [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx), to confirm that a product variant can be added to the cart at the specified quantity.\n\n:::note\n\nLearn more about the links between the product variant and sales channels and inventory items in [this documentation](https://docs.medusajs.com/resources/commerce-modules/product/links-to-other-modules).\n\n:::\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to check whether a product variant has enough inventory quantity before adding them to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":4},{"type":"step","name":"validateLineItemPricesStep","description":"This step validates the specified line item objects to ensure they have prices.\nIf an item doesn't have a price, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateLineItemPricesStep/page.mdx","depth":5},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":6},{"type":"step","name":"createCartsStep","description":"This step creates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.createCartsStep/page.mdx","depth":7},{"type":"workflow","name":"updateTaxLinesWorkflow","description":"This workflow updates a cart's tax lines that are applied on line items and shipping methods. You can update the line item's quantity, unit price, and more. This workflow is executed\nby the [Calculate Taxes Store API Route](https://docs.medusajs.com/api/store#carts\\_postcartsidtaxes).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to update a cart's tax lines in your custom flows.","link":"../core_flows.Cart.Workflows_Cart.updateTaxLinesWorkflow/page.mdx","depth":8},{"type":"workflow","name":"updateCartPromotionsWorkflow","description":"This workflow updates a cart's promotions, applying or removing promotion codes from the cart. It also computes the adjustments\nthat need to be applied to the cart's line items and shipping methods based on the promotions applied. This workflow is used by\n[Add Promotions Line truncated
|
||||
<WorkflowDiagram workflow={{"name":"createCartWorkflow","steps":[{"type":"step","name":"findSalesChannelStep","description":"This step either retrieves a sales channel either using the ID provided as an input, or, if no ID\nis provided, the default sales channel of the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findSalesChannelStep/page.mdx","depth":1},{"type":"step","name":"findOneOrAnyRegionStep","description":"This step retrieves a region either by the provided ID or the first region in the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOneOrAnyRegionStep/page.mdx","depth":1},{"type":"step","name":"findOrCreateCustomerStep","description":"This step either finds a customer matching the specified ID, or finds / create a customer\nmatching the specified email. If both ID and email are provided, ID takes precedence.\nIf the customer is a guest, the email is updated to the provided email.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOrCreateCustomerStep/page.mdx","depth":1},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"2","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":2}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":3},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"Validate that a variant is in-stock before adding to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":4},{"type":"step","name":"validateLineItemPricesStep","description":"This step validates the specified line item objects to ensure they have prices.\nIf an item doesn't have a price, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateLineItemPricesStep/page.mdx","depth":5},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":6},{"type":"step","name":"createCartsStep","description":"This step creates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.createCartsStep/page.mdx","depth":7},{"type":"workflow","name":"updateTaxLinesWorkflow","description":"Update a cart's tax lines.","link":"../core_flows.Cart.Workflows_Cart.updateTaxLinesWorkflow/page.mdx","depth":8},{"type":"workflow","name":"updateCartPromotionsWorkflow","description":"Update a cart's applied promotions to add, replace, or remove them.","link":"../core_flows.Cart.Workflows_Cart.updateCartPromotionsWorkflow/page.mdx","depth":9},{"type":"workflow","name":"refreshPaymentCollectionForCartWorkflow","description":"Refresh a cart's payment collection details.","link":"../core_flows.Cart.Workflows_Cart.refreshPaymentCollectionForCartWorkflow/page.mdx","depth":10},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":10},{"type":"hook","name":"cartCreated","description":"This hook is executed after a cart is created. You can consume this hook to perform custom actions on the created cart.","link":"#cartCreated","depth":11}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+1
-1
@@ -139,7 +139,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"refreshCartItemsWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"2","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":2}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":3},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":4},{"type":"step","name":"updateLineItemsStep","description":"This step updates a cart's line items.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateLineItemsStep/page.mdx","depth":5},{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":6},{"type":"workflow","name":"refreshCartShippingMethodsWorkflow","description":"This workflow refreshes a cart's shipping methods, ensuring that their associated shipping options can still be used on the cart,\nand retrieve their correct pricing after a cart update. This workflow is used by the [refreshCartItemsWorkflow](./page.mdx).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart's shipping method after making updates to the cart.","link":"../core_flows.Cart.Workflows_Cart.refreshCartShippingMethodsWorkflow/page.mdx","depth":7},{"type":"workflow","name":"updateTaxLinesWorkflow","description":"This workflow updates a cart's tax lines that are applied on line items and shipping methods. You can update the line item's quantity, unit price, and more. This workflow is executed\nby the [Calculate Taxes Store API Route](https://docs.medusajs.com/api/store#carts\\_postcartsidtaxes).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to update a cart's tax lines in your custom flows.","link":"../core_flows.Cart.Workflows_Cart.updateTaxLinesWorkflow/page.mdx","depth":8},{"type":"workflow","name":"updateCartPromotionsWorkflow","description":"This workflow updates a cart's promotions, applying or removing promotion codes from the cart. It also computes the adjustments\nthat need to be applied to the cart's line items and shipping methods based on the promotions applied. This workflow is used by\n[Add Promotions Store API Route](https://docs.medusajs.com/api/store#carts\\_postcartsidpromotions).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to update a cart's promotions within your custom flows.","link":"../core_flows.Cart.Workflows_Cart.updateCartPromotionsWorkflow/page.mdx","depth":9},{"type":"workflow","name":"refreshPaymentCollectionForCartWorkflow","description":"This workflow refreshes a cart's payment collection, which is useful once the cart is created or when its details\nare updated. If the cart's total changes to the amount in its payment collection, the payment collection's payment sessions are \ndeleted. It also syncs the payment collection's amount, currency code, and other details with the details in the cart.\n\nThis workflow is used by other cart-related workflows, such as the [refreshCartItemsWorkflow](./page.mdx) to refresh the cart's\npayment collection Line truncated
|
||||
<WorkflowDiagram workflow={{"name":"refreshCartItemsWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"2","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":2}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":3},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":4},{"type":"step","name":"updateLineItemsStep","description":"This step updates a cart's line items.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateLineItemsStep/page.mdx","depth":5},{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":6},{"type":"workflow","name":"refreshCartShippingMethodsWorkflow","description":"Refresh a cart's shipping methods after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartShippingMethodsWorkflow/page.mdx","depth":7},{"type":"workflow","name":"updateTaxLinesWorkflow","description":"Update a cart's tax lines.","link":"../core_flows.Cart.Workflows_Cart.updateTaxLinesWorkflow/page.mdx","depth":8},{"type":"workflow","name":"updateCartPromotionsWorkflow","description":"Update a cart's applied promotions to add, replace, or remove them.","link":"../core_flows.Cart.Workflows_Cart.updateCartPromotionsWorkflow/page.mdx","depth":9},{"type":"workflow","name":"refreshPaymentCollectionForCartWorkflow","description":"Refresh a cart's payment collection details.","link":"../core_flows.Cart.Workflows_Cart.refreshPaymentCollectionForCartWorkflow/page.mdx","depth":10}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+1
-5
@@ -130,16 +130,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"refreshCartShippingMethodsWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"when","condition":"{\n return !!listShippingOptionsInput?.length\n }","depth":"3","steps":[{"type":"workflow","name":"listShippingOptionsForCartWithPricingWorkflow","description":"This workflow lists shipping options that can be used during checkout for a cart. It also retrieves the prices\nof these shipping options, including calculated prices that may be retrieved from third-party providers.\n\nThis workflow is executed in other cart-related workflows, such as [addShippingMethodToCartWorkflow](../core_flows.Cart.Workflows_Cart.addShippingMethodToCartWorkflow/page.mdx) to retrieve the\nprice of the shipping method being added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to retrieve the shipping options of a cart and their prices \nin your custom flows.","link":"../core_flows.Cart.Workflows_Cart.listShippingOptionsForCartWithPricingWorkflow/page.mdx","depth":3},{"type":"step","name":"removeShippingMethodFromCartStep","description":"This step removes shipping methods from a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.removeShippingMethodFromCartStep/page.mdx","depth":3},{"type":"step","name":"updateShippingMethodsStep","description":"This step updates a cart's shipping methods.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateShippingMethodsStep/page.mdx","depth":3}]}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"refreshCartShippingMethodsWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"when","condition":"{\n return !!listShippingOptionsInput?.length\n }","depth":"3","steps":[{"type":"workflow","name":"listShippingOptionsForCartWithPricingWorkflow","description":"List a cart's shipping options with prices.","link":"../core_flows.Cart.Workflows_Cart.listShippingOptionsForCartWithPricingWorkflow/page.mdx","depth":3},{"type":"step","name":"removeShippingMethodFromCartStep","description":"This step removes shipping methods from a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.removeShippingMethodFromCartStep/page.mdx","depth":3},{"type":"step","name":"updateShippingMethodsStep","description":"This step updates a cart's shipping methods.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateShippingMethodsStep/page.mdx","depth":3}]}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RefreshCartShippingMethodsWorkflowInput","type":"[RefreshCartShippingMethodsWorkflowInput](../../../../types/core_flows.RefreshCartShippingMethodsWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart to refresh.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="refreshCartShippingMethodsWorkflow"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="refreshCartShippingMethodsWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-5
@@ -134,16 +134,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"refreshPaymentCollectionForCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"when","condition":"{\n const valueIsEqual = MathBN.eq(\n cart.payment_collection?.raw_amount ?? -1,\n cart.raw_total\n )\n\n if (valueIsEqual) {\n return cart.payment_collection.currency_code !== cart.currency_code\n }\n\n return true\n }","depth":"3","steps":[{"type":"workflow","name":"deletePaymentSessionsWorkflow","description":"This workflow deletes one or more payment sessions. It's used by other workflows, like\nrefreshPaymentCollectionForCartWorkflow to delete payment sessions when the cart's total changes.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you\nto delete payment sessions in your custom flows.","link":"../../../../Payment_Collection/Workflows_Payment_Collection/functions/core_flows.Payment_Collection.Workflows_Payment_Collection.deletePaymentSessionsWorkflow/page.mdx","depth":3},{"type":"step","name":"updatePaymentCollectionStep","description":"This step updates payment collections matching the specified filters.","link":"../../../../Payment_Collection/Steps_Payment_Collection/functions/core_flows.Payment_Collection.Steps_Payment_Collection.updatePaymentCollectionStep/page.mdx","depth":3}]}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"refreshPaymentCollectionForCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"when","condition":"{\n const valueIsEqual = MathBN.eq(\n cart.payment_collection?.raw_amount ?? -1,\n cart.raw_total\n )\n\n if (valueIsEqual) {\n return cart.payment_collection.currency_code !== cart.currency_code\n }\n\n return true\n }","depth":"3","steps":[{"type":"workflow","name":"deletePaymentSessionsWorkflow","description":"Delete payment sessions.","link":"../../../../Payment_Collection/Workflows_Payment_Collection/functions/core_flows.Payment_Collection.Workflows_Payment_Collection.deletePaymentSessionsWorkflow/page.mdx","depth":3},{"type":"step","name":"updatePaymentCollectionStep","description":"This step updates payment collections matching the specified filters.","link":"../../../../Payment_Collection/Steps_Payment_Collection/functions/core_flows.Payment_Collection.Steps_Payment_Collection.updatePaymentCollectionStep/page.mdx","depth":3}]}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RefreshPaymentCollectionForCartWorklowInput","type":"[RefreshPaymentCollectionForCartWorklowInput](../../../../types/core_flows.RefreshPaymentCollectionForCartWorklowInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart to refresh.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="refreshPaymentCollectionForCartWorkflow"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="refreshPaymentCollectionForCartWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-5
@@ -140,16 +140,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"transferCartCustomerWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":3},{"type":"when","condition":"shouldTransfer","depth":"4","steps":[{"type":"step","name":"updateCartsStep","description":"This step updates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateCartsStep/page.mdx","depth":4},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"This workflow refreshes a cart to ensure its prices, promotion codes, taxes, and other details are applied correctly. It's useful\nafter making a chnge to a cart, such as after adding an item to the cart or adding a promotion code.\n\nThis workflow is used by other cart-related workflows, such as the [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx) after an item\nis added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart after making updates to it in your\ncustom flows.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":4}]}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"transferCartCustomerWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":2},{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":3},{"type":"when","condition":"shouldTransfer","depth":"4","steps":[{"type":"step","name":"updateCartsStep","description":"This step updates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateCartsStep/page.mdx","depth":4},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"Refresh a cart's details after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":4}]}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"TransferCartCustomerWorkflowInput","type":"[TransferCartCustomerWorkflowInput](../../../../types/core_flows.TransferCartCustomerWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The cart ownership transfer details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The ID of the customer to transfer the cart to.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="transferCartCustomerWorkflow"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="transferCartCustomerWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
-4
@@ -149,10 +149,6 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
<TypeList types={[{"name":"UpdateCartPromotionsWorkflowInput","type":"[UpdateCartPromotionsWorkflowInput](../../../../types/core_flows.UpdateCartPromotionsWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the promotion updates on a cart.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"The promotion codes to add to the cart, remove from the cart,\nor replace all existing promotions in the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"action","type":"[ADD](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#add) \\| [REMOVE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#remove) \\| [REPLACE](../../../../../utils/PromotionUtils/enums/utils.PromotionUtils.PromotionActions/page.mdx#replace)","description":"The action to perform with the specified promotion codes.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateCartPromotionsWorkflow"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateCartPromotionsWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-5
@@ -200,16 +200,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"updateCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"findSalesChannelStep","description":"This step either retrieves a sales channel either using the ID provided as an input, or, if no ID\nis provided, the default sales channel of the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findSalesChannelStep/page.mdx","depth":2},{"type":"step","name":"findOrCreateCustomerStep","description":"This step either finds a customer matching the specified ID, or finds / create a customer\nmatching the specified email. If both ID and email are provided, ID takes precedence.\nIf the customer is a guest, the email is updated to the provided email.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOrCreateCustomerStep/page.mdx","depth":2},{"type":"when","condition":"{\n return !!data.input.region_id\n }","depth":"3","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":3}]},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":4},{"type":"when","condition":"{\n return !!regionUpdated\n }","depth":"5","steps":[{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":5}]},{"type":"step","name":"updateCartsStep","description":"This step updates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateCartsStep/page.mdx","depth":6},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":6},{"type":"when","condition":"{\n return !!regionUpdated\n }","depth":"7","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":7},{"type":"step","name":"deleteLineItemsStep","description":"This step deletes line items.","link":"../../../../Line_Item/Steps_Line_Item/functions/core_flows.Line_Item.Steps_Line_Item.deleteLineItemsStep/page.mdx","depth":7}]},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"This workflow refreshes a cart to ensure its prices, promotion codes, taxes, and other details are applied correctly. It's useful\nafter making a chnge to a cart, such as after adding an item to the cart or adding a promotion code.\n\nThis workflow is used by other cart-related workflows, such as the [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx) after an item\nis added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart after making updates to it in your\ncustom flows.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":8},{"type":"hook","name":"cartUpdated","description":"This hook is executed after a cart is update. You can consume this hook to perform custom actions on the updated cart.","link":"#cartUpdated","depth":9}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"updateCartWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"findSalesChannelStep","description":"This step either retrieves a sales channel either using the ID provided as an input, or, if no ID\nis provided, the default sales channel of the first store.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findSalesChannelStep/page.mdx","depth":2},{"type":"step","name":"findOrCreateCustomerStep","description":"This step either finds a customer matching the specified ID, or finds / create a customer\nmatching the specified email. If both ID and email are provided, ID takes precedence.\nIf the customer is a guest, the email is updated to the provided email.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.findOrCreateCustomerStep/page.mdx","depth":2},{"type":"when","condition":"{\n return !!data.input.region_id\n }","depth":"3","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":3}]},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":4},{"type":"when","condition":"{\n return !!regionUpdated\n }","depth":"5","steps":[{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":5}]},{"type":"step","name":"updateCartsStep","description":"This step updates a cart.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.updateCartsStep/page.mdx","depth":6},{"type":"step","name":"emitEventStep","description":"Emit an event.","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.emitEventStep/page.mdx","depth":6},{"type":"when","condition":"{\n return !!regionUpdated\n }","depth":"7","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":7},{"type":"step","name":"deleteLineItemsStep","description":"This step deletes line items.","link":"../../../../Line_Item/Steps_Line_Item/functions/core_flows.Line_Item.Steps_Line_Item.deleteLineItemsStep/page.mdx","depth":7}]},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"Refresh a cart's details after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":8},{"type":"hook","name":"cartUpdated","description":"This hook is executed after a cart is update. You can consume this hook to perform custom actions on the updated cart.","link":"#cartUpdated","depth":9}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCartWorkflowInput","type":"[UpdateCartWorkflowInput](../../../../types/core_flows.UpdateCartWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update the cart, along with custom data that's passed to the workflow's hooks.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the cart to update.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"promo_codes","type":"`string`[]","description":"An array of promotional codes applied on the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"region_id","type":"`string`","description":"The ID of the cart's region.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`null` \\| `string`","description":"The ID of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"sales_channel_id","type":"`null` \\| `string`","description":"The ID of the cart's sales channel.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email address of the cart's customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code for the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Custom key-value pairs of data related to the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's shipping address. You can either update the cart's existing shipping address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string`","description":"The last name of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`string`","description":"The first line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`string`","description":"The second line of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`string`","description":"The city of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`string`","description":"The ISO two country code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`string`","description":"The province of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`string`","description":"The postal code of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string`","description":"The phone of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"billing_address","type":"`null` \\| [UpdateAddressDTO](../../../../../cart/interfaces/cart.UpdateAddressDTO/page.mdx) \\| [CreateAddressDTO](../../../../../cart/interfaces/cart.CreateAddressDTO/page.mdx)","description":"The cart's billing address. You can either update the cart's existing billing address, or create a new one.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`string`","description":"The company of the address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string`","description":"The first name of the address.","optLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateCartWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-5
@@ -152,16 +152,12 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"updateLineItemInCartWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"4","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":4}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":5},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"This workflow validates that product variants are in-stock at the specified sales channel, before adding them or updating their quantity in the cart. If a variant doesn't have sufficient quantity in-stock,\nthe workflow throws an error. If all variants have sufficient inventory, the workflow returns the cart's items with their inventory details.\n\nThis workflow is useful when confirming that a product variant has sufficient quantity to be added to or updated in the cart. It's executed\nby other cart-related workflows, such as [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx), to confirm that a product variant can be added to the cart at the specified quantity.\n\n:::note\n\nLearn more about the links between the product variant and sales channels and inventory items in [this documentation](https://docs.medusajs.com/resources/commerce-modules/product/links-to-other-modules).\n\n:::\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to check whether a product variant has enough inventory quantity before adding them to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":6},{"type":"step","name":"updateLineItemsStepWithSelector","description":"This step updates line items.","link":"../../../../Line_Item/Steps_Line_Item/functions/core_flows.Line_Item.Steps_Line_Item.updateLineItemsStepWithSelector/page.mdx","depth":7},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"This workflow refreshes a cart to ensure its prices, promotion codes, taxes, and other details are applied correctly. It's useful\nafter making a chnge to a cart, such as after adding an item to the cart or adding a promotion code.\n\nThis workflow is used by other cart-related workflows, such as the [addToCartWorkflow](../core_flows.Cart.Workflows_Cart.addToCartWorkflow/page.mdx) after an item\nis added to the cart.\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to refresh the cart after making updates to it in your\ncustom flows.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":8}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"updateLineItemInCartWorkflow","steps":[{"type":"step","name":"useQueryGraphStep","description":"This step fetches data across modules using the Query.\n\nLearn more in the [Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx","depth":1},{"type":"step","name":"validateCartStep","description":"This step validates a cart to ensure it exists and is not completed.\nIf not valid, the step throws an error.\n\n:::tip\n\nYou can use the [retrieveCartStep](../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.retrieveCartStep/page.mdx) to retrieve a cart's details.\n\n:::","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateCartStep/page.mdx","depth":2},{"type":"hook","name":"validate","description":"This hook is executed before all operations. You can consume this hook to perform any custom validation. If validation fails, you can throw an error to stop the workflow execution.","link":"#validate","depth":3},{"type":"when","condition":"{\n return !!variantIds.length\n }","depth":"4","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":4}]},{"type":"step","name":"validateVariantPricesStep","description":"This step validates the specified variant objects to ensure they have prices.\nIf not valid, the step throws an error.","link":"../../../Steps_Cart/functions/core_flows.Cart.Steps_Cart.validateVariantPricesStep/page.mdx","depth":5},{"type":"workflow","name":"confirmVariantInventoryWorkflow","description":"Validate that a variant is in-stock before adding to the cart.","link":"../core_flows.Cart.Workflows_Cart.confirmVariantInventoryWorkflow/page.mdx","depth":6},{"type":"step","name":"updateLineItemsStepWithSelector","description":"This step updates line items.","link":"../../../../Line_Item/Steps_Line_Item/functions/core_flows.Line_Item.Steps_Line_Item.updateLineItemsStepWithSelector/page.mdx","depth":7},{"type":"workflow","name":"refreshCartItemsWorkflow","description":"Refresh a cart's details after an update.","link":"../core_flows.Cart.Workflows_Cart.refreshCartItemsWorkflow/page.mdx","depth":8}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateLineItemInCartWorkflowInputDTO","type":"[UpdateLineItemInCartWorkflowInputDTO](../../../../../types/interfaces/types.UpdateLineItemInCartWorkflowInputDTO/page.mdx)","optional":false,"defaultValue":"","description":"The details of the line item to update.","expandable":false,"children":[{"name":"cart_id","type":"`string`","description":"The ID of the cart that the line item belongs to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"item_id","type":"`string`","description":"The ID of the line item to update.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"update","type":"Partial<[UpdateLineItemDTO](../../../../../cart/interfaces/cart.UpdateLineItemDTO/page.mdx)>","description":"The details to update in the line item.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the line item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"subtitle","type":"`string`","description":"The subtitle of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"thumbnail","type":"`string`","description":"The thumbnail of the line item.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"cart_id","type":"`string`","description":"The associated cart's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_id","type":"`string`","description":"The associated product's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_title","type":"`string`","description":"The title of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_description","type":"`string`","description":"The description of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_subtitle","type":"`string`","description":"The subtitle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type","type":"`string`","description":"The type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_type_id","type":"`string`","description":"The ID of type of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_collection","type":"`string`","description":"The collection of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"product_handle","type":"`string`","description":"The handle of the associated product.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_id","type":"`string`","description":"The associated variant's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_sku","type":"`string`","description":"The SKU of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_barcode","type":"`string`","description":"The barcode of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_title","type":"`string`","description":"The title of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"variant_option_values","type":"`Record<string, unknown>`","description":"The option values of the associated variant.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"requires_shipping","type":"`boolean`","description":"Whether the line item requires shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_discountable","type":"`boolean`","description":"Whether the line item is discountable.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_tax_inclusive","type":"`boolean`","description":"Whether the line item's amount is tax inclusive.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_custom_price","type":"`boolean`","description":"Whether the line item's amount is a custom price.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"compare_at_unit_price","type":"[BigNumberInput](../../../../../cart/types/cart.BigNumberInput/page.mdx)","description":"The calculated price of the line item after applying promotions.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":trLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"undefined","type":"`undefined`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateLineItemInCartWorkflow"/>
|
||||
|
||||
## Hooks
|
||||
|
||||
Hooks allow you to inject custom functionalities into the workflow. You'll receive data from the workflow, as well as additional data sent through an HTTP request.
|
||||
|
||||
+1
-1
@@ -37,4 +37,4 @@ const data = validateExistingPaymentCollectionStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateExistingPaymentCollectionStepInput","type":"[ValidateExistingPaymentCollectionStepInput](../../../../types/core_flows.ValidateExistingPaymentCollectionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx) & `object`","description":"The cart to validate.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeriLine truncated
|
||||
<TypeList types={[{"name":"ValidateExistingPaymentCollectionStepInput","type":"[ValidateExistingPaymentCollectionStepInput](../../../../types/core_flows.ValidateExistingPaymentCollectionStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the cart to validate its payment collection.","expandable":false,"children":[{"name":"cart","type":"[CartDTO](../../../../../cart/interfaces/cart.CartDTO/page.mdx) & `object`","description":"The cart to validate.","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":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_subtotal","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item subtotal of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"item_tax_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The item tax total of the cart.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../cart/types/cart.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"original_total","type":"[BigNumberValue](../../../../../cart/types/cart.BigNumberValue/page.mdx)","description":"The original total of the cart.","optional":false,"defaLine truncated
|
||||
+1
-1
@@ -32,4 +32,4 @@ removeRemoteLinkStep([{
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"DeleteEntityInput","type":"[DeleteEntityInput](../../../../../modules_sdk/types/modules_sdk.DeleteEntityInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteEntityInput","type":"`object`","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeRemoteLinkStep"/>
|
||||
<TypeList types={[{"name":"DeleteEntityInput","type":"[DeleteEntityInput](../../../../../modules_sdk/types/modules_sdk.DeleteEntityInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","expandable":false,"children":[{"name":"DeleteEntityInput","type":"`object`","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="removeRemoteLinkStep"/>
|
||||
+1
-1
@@ -33,7 +33,7 @@ const data = createCustomerAddressesStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateCustomerAddressesStepInput","type":"[CreateCustomerAddressesStepInput](../../../../types/core_flows.CreateCustomerAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomerAddressesStep"/>
|
||||
<TypeList types={[{"name":"CreateCustomerAddressesStepInput","type":"[CreateCustomerAddressesStepInput](../../../../types/core_flows.CreateCustomerAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create one or more customer addresses.","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomerAddressesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -28,7 +28,7 @@ const data = createCustomersStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateCustomersStepInput","type":"[CreateCustomersStepInput](../../../../types/core_flows.CreateCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`null` \\| `string`","description":"Who created the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"Whether the customer has an account.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"Omit<[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx), \"customer_id\">[]","description":"The addresses of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomersStep"/>
|
||||
<TypeList types={[{"name":"CreateCustomersStepInput","type":"[CreateCustomersStepInput](../../../../types/core_flows.CreateCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create one or more customers.","expandable":false,"children":[{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`null` \\| `string`","description":"Who created the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"Whether the customer has an account.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"Omit<[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx), \"customer_id\">[]","description":"The addresses of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomersStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteCustomerAddressesStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteCustomerAddressesStep({})
|
||||
const data = deleteCustomerAddressesStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteCustomerAddressesStepInput","type":"[DeleteCustomerAddressesStepInput](../../../../types/core_flows.DeleteCustomerAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteCustomerAddressesStepInput","type":"`string`[]","description":"The IDs of the customer addresses to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomerAddressesStep"/>
|
||||
<TypeList types={[{"name":"DeleteCustomerAddressesStepInput","type":"[DeleteCustomerAddressesStepInput](../../../../types/core_flows.DeleteCustomerAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the customer addresses to delete.","expandable":false,"children":[{"name":"DeleteCustomerAddressesStepInput","type":"`string`[]","description":"The IDs of the customer addresses to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomerAddressesStep"/>
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteCustomersStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteCustomersStep({})
|
||||
const data = deleteCustomersStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteCustomersStepInput","type":"[DeleteCustomersStepInput](../../../../types/core_flows.DeleteCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteCustomersStepInput","type":"`string`[]","description":"The IDs of the customers to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomersStep"/>
|
||||
<TypeList types={[{"name":"DeleteCustomersStepInput","type":"[DeleteCustomersStepInput](../../../../types/core_flows.DeleteCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the customers to delete.","expandable":false,"children":[{"name":"DeleteCustomersStepInput","type":"`string`[]","description":"The IDs of the customers to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomersStep"/>
|
||||
+1
-1
@@ -43,4 +43,4 @@ const data = maybeUnsetDefaultBillingAddressesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"MaybeUnsetDefaultBillingAddressStepInput","type":"[MaybeUnsetDefaultBillingAddressStepInput](../../../../types/core_flows.MaybeUnsetDefaultBillingAddressStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"create","type":"[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx)[]","description":"The addresses being created. If the address has \nthe `is_default_billing` property set to `true`,\nthe existing default billing address of the customer will be unset.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"update","type":"`object`","description":"The addresses being updated.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The selector to identify the customers to unset their default billing address.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string` \\| `string`[]","description":"Filter addresses by the associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](../../../../../customer/interfaces/customer.FilterLine truncated
|
||||
<TypeList types={[{"name":"MaybeUnsetDefaultBillingAddressStepInput","type":"[MaybeUnsetDefaultBillingAddressStepInput](../../../../types/core_flows.MaybeUnsetDefaultBillingAddressStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The addresses being created or updated.","expandable":false,"children":[{"name":"create","type":"[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx)[]","description":"The addresses being created. If the address has \nthe `is_default_billing` property set to `true`,\nthe existing default billing address of the customer will be unset.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"update","type":"`object`","description":"The addresses being updated.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The selector to identify the customers to unset their default billing address.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string` \\| `string`[]","description":"Filter addresses by the associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](../../../..Line truncated
|
||||
+1
-1
@@ -43,4 +43,4 @@ const data = maybeUnsetDefaultShippingAddressesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"MaybeUnsetDefaultShippingAddressesStepInput","type":"[MaybeUnsetDefaultShippingAddressesStepInput](../../../../types/core_flows.MaybeUnsetDefaultShippingAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"create","type":"[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx)[]","description":"The addresses being created. If the address has\nthe `is_default_shipping` property set to `true`,\nthe existing default shipping address of the customer will be unset.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"update","type":"`object`","description":"The addresses being updated.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The selector to identify the customers to unset their default shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string` \\| `string`[]","description":"Filter addresses by the associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](../../../../../customer/interfaces/custLine truncated
|
||||
<TypeList types={[{"name":"MaybeUnsetDefaultShippingAddressesStepInput","type":"[MaybeUnsetDefaultShippingAddressesStepInput](../../../../types/core_flows.MaybeUnsetDefaultShippingAddressesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The addresses being created or updated.","expandable":false,"children":[{"name":"create","type":"[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx)[]","description":"The addresses being created. If the address has\nthe `is_default_shipping` property set to `true`,\nthe existing default shipping address of the customer will be unset.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"customer_id","type":"`string`","description":"The associated customer's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"update","type":"`object`","description":"The addresses being updated.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The selector to identify the customers to unset their default shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer_id","type":"`string` \\| `string`[]","description":"Filter addresses by the associated customer's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"customer","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](Line truncated
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateCustomerAddressesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCustomerAddresseStepInput","type":"[UpdateCustomerAddresseStepInput](../../../../types/core_flows.UpdateCustomerAddresseStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The filters to select the customer addresses to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaLine truncated
|
||||
<TypeList types={[{"name":"UpdateCustomerAddresseStepInput","type":"[UpdateCustomerAddresseStepInput](../../../../types/core_flows.UpdateCustomerAddresseStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update one or more customer addresses.","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerAddressProps](../../../../../customer/interfaces/customer.FilterableCustomerAddressProps/page.mdx)","description":"The filters to select the customer addresses to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for addresses by properties such as name and street using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer address by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter addresses by name.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"is_default_shipping","type":"`boolean` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<boolean>","description":"Filter addresses by whether they're the default for shipping.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateCustomersStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCustomersStepInput","type":"[UpdateCustomersStepInput](../../../../types/core_flows.UpdateCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerProps](../../../../../customer/interfaces/customer.FilterableCustomerProps/page.mdx)","description":"The filters to select the customers to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customers by properties such as name and email using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter by email.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"groups","type":"`string` \\| `string`[] \\| [FilterableCustomerGroupProps](../../../../../customer/interfaces/customer.FilterableCustomerGroupProps/page.mdx)","description":"Filter by associated customer group.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customer groups by name using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer group by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` Line truncated
|
||||
<TypeList types={[{"name":"UpdateCustomersStepInput","type":"[UpdateCustomersStepInput](../../../../types/core_flows.UpdateCustomersStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update one or more customers.","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerProps](../../../../../customer/interfaces/customer.FilterableCustomerProps/page.mdx)","description":"The filters to select the customers to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customers by properties such as name and email using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter by email.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"groups","type":"`string` \\| `string`[] \\| [FilterableCustomerGroupProps](../../../../../customer/interfaces/customer.FilterableCustomerGroupProps/page.mdx)","description":"Filter by associated customer group.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customer groups by name using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer group by.","optional":true,"defaultValue":"","expandable":false,"childLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -34,4 +34,4 @@ const data = validateCustomerAccountCreation({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateCustomerAccountWorkflowInput","type":"[CreateCustomerAccountWorkflowInput](../../../../types/core_flows.CreateCustomerAccountWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"authIdentityId","type":"`string`","description":"The ID of the auth identity to attach the customer to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customerData","type":"[CreateCustomerDTO](../../../../../customer/interfaces/customer.CreateCustomerDTO/page.mdx)","description":"The details of the customer to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`null` \\| `string`","description":"Who created the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"Whether the customer has an account.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"Omit<[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx), \"customer_id\">[]","description":"The addresses of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateCustomerAccountCreation"/>
|
||||
<TypeList types={[{"name":"CreateCustomerAccountWorkflowInput","type":"[CreateCustomerAccountWorkflowInput](../../../../types/core_flows.CreateCustomerAccountWorkflowInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of the customer account to create.","expandable":false,"children":[{"name":"authIdentityId","type":"`string`","description":"The ID of the auth identity to attach the customer to.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"customerData","type":"[CreateCustomerDTO](../../../../../customer/interfaces/customer.CreateCustomerDTO/page.mdx)","description":"The details of the customer to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company_name","type":"`null` \\| `string`","description":"The company name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`null` \\| `string`","description":"The email of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`null` \\| `string`","description":"Who created the customer.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"has_account","type":"`boolean`","description":"Whether the customer has an account.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"addresses","type":"Omit<[CreateCustomerAddressDTO](../../../../../customer/interfaces/customer.CreateCustomerAddressDTO/page.mdx), \"customer_id\">[]","description":"The addresses of the customer.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"address_name","type":"`null` \\| `string`","description":"The address's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_shipping","type":"`boolean`","description":"Whether the address is default shipping.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default_billing","type":"`boolean`","description":"Whether the address is the default for billing.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"company","type":"`null` \\| `string`","description":"The company.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The address 1.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The address 2.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The country code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateCustomerAccountCreation"/>
|
||||
+1
-1
@@ -153,7 +153,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"createCustomerAccountWorkflow","steps":[{"type":"step","name":"validateCustomerAccountCreation","description":"This step validates the input data for creating a customer account.\nThe step throws an error if:\n\n- The email is missing\n- A customer with the email already exists and has an account\n- A guest customer with the email already exists","link":"../../../Steps_Customer/functions/core_flows.Customer.Steps_Customer.validateCustomerAccountCreation/page.mdx","depth":1},{"type":"workflow","name":"createCustomersWorkflow","description":"This workflow creates one or more customers. It's used by the [Create Customer Admin API Route](https://docs.medusajs.com/api/admin#customers\\_postcustomers).\n\nThis workflow has a hook that allows you to perform custom actions on the created customer. You can see an example in [this guide](https://docs.medusajs.com/resources/commerce-modules/customer/extend).\n\nYou can also use this workflow within your customizations or your own custom workflows, allowing you to wrap custom logic around creating customers.","link":"../core_flows.Customer.Workflows_Customer.createCustomersWorkflow/page.mdx","depth":2},{"type":"step","name":"setAuthAppMetadataStep","description":"This step sets the `app_metadata` property of an auth identity. This is useful to\nassociate a user (whether it's an admin user or customer) with an auth identity\nthat allows them to authenticate into Medusa.\n\nYou can learn more about auth identites in \n[this documentation](https://docs.medusajs.com/resources/commerce-modules/auth/auth-identity-and-actor-types).\n\nTo use this for a custom actor type, check out [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/create-actor-type)\nthat explains how to create a custom `manager` actor type and manage its users.","link":"../../../../Auth/Steps_Auth/functions/core_flows.Auth.Steps_Auth.setAuthAppMetadataStep/page.mdx","depth":3}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"createCustomerAccountWorkflow","steps":[{"type":"step","name":"validateCustomerAccountCreation","description":"This step validates the input data for creating a customer account.\nThe step throws an error if:\n\n- The email is missing\n- A customer with the email already exists and has an account\n- A guest customer with the email already exists","link":"../../../Steps_Customer/functions/core_flows.Customer.Steps_Customer.validateCustomerAccountCreation/page.mdx","depth":1},{"type":"workflow","name":"createCustomersWorkflow","description":"Create one or more customers.","link":"../core_flows.Customer.Workflows_Customer.createCustomersWorkflow/page.mdx","depth":2},{"type":"step","name":"setAuthAppMetadataStep","description":"This step sets the `app_metadata` property of an auth identity. This is useful to\nassociate a user (whether it's an admin user or customer) with an auth identity\nthat allows them to authenticate into Medusa.\n\nYou can learn more about auth identites in \n[this documentation](https://docs.medusajs.com/resources/commerce-modules/auth/auth-identity-and-actor-types).\n\nTo use this for a custom actor type, check out [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/create-actor-type)\nthat explains how to create a custom `manager` actor type and manage its users.","link":"../../../../Auth/Steps_Auth/functions/core_flows.Auth.Steps_Auth.setAuthAppMetadataStep/page.mdx","depth":3}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+1
-1
@@ -138,7 +138,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"removeCustomerAccountWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"workflow","name":"deleteCustomersWorkflow","description":"This workflow deletes one or more customers. It's used by the \n[removeCustomerAccountWorkflow](./page.mdx).\n\nYou can use this workflow within your customizations or your own custom workflows, allowing you to \ndelete customers in your custom flows.","link":"../core_flows.Customer.Workflows_Customer.deleteCustomersWorkflow/page.mdx","depth":2},{"type":"when","condition":"{\n return !!customers[0]?.has_account\n }","depth":"3","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":3},{"type":"step","name":"setAuthAppMetadataStep","description":"This step sets the `app_metadata` property of an auth identity. This is useful to\nassociate a user (whether it's an admin user or customer) with an auth identity\nthat allows them to authenticate into Medusa.\n\nYou can learn more about auth identites in \n[this documentation](https://docs.medusajs.com/resources/commerce-modules/auth/auth-identity-and-actor-types).\n\nTo use this for a custom actor type, check out [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/create-actor-type)\nthat explains how to create a custom `manager` actor type and manage its users.","link":"../../../../Auth/Steps_Auth/functions/core_flows.Auth.Steps_Auth.setAuthAppMetadataStep/page.mdx","depth":3}]}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"removeCustomerAccountWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"workflow","name":"deleteCustomersWorkflow","description":"Delete one or more customers.","link":"../core_flows.Customer.Workflows_Customer.deleteCustomersWorkflow/page.mdx","depth":2},{"type":"when","condition":"{\n return !!customers[0]?.has_account\n }","depth":"3","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":3},{"type":"step","name":"setAuthAppMetadataStep","description":"This step sets the `app_metadata` property of an auth identity. This is useful to\nassociate a user (whether it's an admin user or customer) with an auth identity\nthat allows them to authenticate into Medusa.\n\nYou can learn more about auth identites in \n[this documentation](https://docs.medusajs.com/resources/commerce-modules/auth/auth-identity-and-actor-types).\n\nTo use this for a custom actor type, check out [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/create-actor-type)\nthat explains how to create a custom `manager` actor type and manage its users.","link":"../../../../Auth/Steps_Auth/functions/core_flows.Auth.Steps_Auth.setAuthAppMetadataStep/page.mdx","depth":3}]}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+2
-2
@@ -22,7 +22,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createCustomerGroupsStep({
|
||||
"name": "Arlie"
|
||||
"name": "Patricia"
|
||||
})
|
||||
}
|
||||
)
|
||||
@@ -31,7 +31,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateCustomerGroupsStepInput","type":"[CreateCustomerGroupsStepInput](../../../../types/core_flows.CreateCustomerGroupsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the customer group.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`string`","description":"Who created the customer group. For example,\nthe ID of the user that created the customer group.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomerGroupsStep"/>
|
||||
<TypeList types={[{"name":"CreateCustomerGroupsStepInput","type":"[CreateCustomerGroupsStepInput](../../../../types/core_flows.CreateCustomerGroupsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create customer groups.","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the customer group.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"[MetadataType](../../../../../customer/types/customer.MetadataType/page.mdx)","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"created_by","type":"`string`","description":"Who created the customer group. For example,\nthe ID of the user that created the customer group.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createCustomerGroupsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteCustomerGroupStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteCustomerGroupStep({})
|
||||
const data = deleteCustomerGroupStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteCustomerGroupsStepInput","type":"[DeleteCustomerGroupsStepInput](../../../../types/core_flows.DeleteCustomerGroupsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteCustomerGroupsStepInput","type":"`string`[]","description":"The IDs of the customer groups to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomerGroupStep"/>
|
||||
<TypeList types={[{"name":"DeleteCustomerGroupsStepInput","type":"[DeleteCustomerGroupsStepInput](../../../../types/core_flows.DeleteCustomerGroupsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the customer groups to delete.","expandable":false,"children":[{"name":"DeleteCustomerGroupsStepInput","type":"`string`[]","description":"The IDs of the customer groups to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteCustomerGroupStep"/>
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateCustomerGroupsStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateCustomerGroupStepInput","type":"[UpdateCustomerGroupStepInput](../../../../types/core_flows.UpdateCustomerGroupStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerGroupProps](../../../../../customer/interfaces/customer.FilterableCustomerGroupProps/page.mdx)","description":"The filters to select the customer groups to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customer groups by name using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer group by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter customer groups by name.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"customers","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](../../../../../customer/interfaces/customer.FilterableCustomerProps/page.mdx)","description":"Filter customer groups by associated customers.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customers by properties such as name and email using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{Line truncated
|
||||
<TypeList types={[{"name":"UpdateCustomerGroupStepInput","type":"[UpdateCustomerGroupStepInput](../../../../types/core_flows.UpdateCustomerGroupStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update customer groups.","expandable":false,"children":[{"name":"selector","type":"[FilterableCustomerGroupProps](../../../../../customer/interfaces/customer.FilterableCustomerGroupProps/page.mdx)","description":"The filters to select the customer groups to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customer groups by name using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer group by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| [OperatorMap](../../../../../customer/types/customer.OperatorMap/page.mdx)<string>","description":"Filter customer groups by name.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$or","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$eq","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T> \\| [ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ne","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$in","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$nin","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$not","type":"[Query](../../../../../customer/types/customer.Query/page.mdx)<T>","description":"API wrapper around the remoteQuery","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$gte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lt","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$lte","type":"[ExpandScalar](../../../../../customer/types/customer.ExpandScalar/page.mdx)<T>","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$like","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$re","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$ilike","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$fulltext","type":"`string`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$overlap","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contains","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$contained","type":"`string`[]","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"$exists","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"customers","type":"`string` \\| `string`[] \\| [FilterableCustomerProps](../../../../../customer/interfaces/customer.FilterableCustomerProps/page.mdx)","description":"Filter customer groups by associated customers.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"q","type":"`string`","description":"Searches for customers by properties such as name and email using this search term.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"id","type":"`string` \\| `string`[]","description":"The IDs to filter the customer by.","optional":true,"defaultValue":"",Line truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -37,4 +37,4 @@ const data = createDefaultStoreStep({
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"StoreDTO","type":"[StoreDTO](../../../../../store/interfaces/store.StoreDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, any>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created at of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated at of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"supported_currencies","type":"[StoreCurrencyDTO](../../../../../store/interfaces/store.StoreCurrencyDTO/page.mdx)[]","description":"The supported currency codes of the store.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the store currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the store currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default","type":"`boolean`","description":"Whether the currency is the default one for the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"store_id","type":"`string`","description":"The store ID associated with the currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`null` \\| `string`","description":"The deleted date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"default_sales_channel_id","type":"`string`","description":"The associated default sales channel's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_region_id","type":"`string`","description":"The associated default region's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_location_id","type":"`string`","description":"The associated default location's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createDefaultStoreStep"/>
|
||||
<TypeList types={[{"name":"StoreDTO","type":"[StoreDTO](../../../../../store/interfaces/store.StoreDTO/page.mdx)","optional":false,"defaultValue":"","description":"The store details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, any>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created at of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated at of the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"supported_currencies","type":"[StoreCurrencyDTO](../../../../../store/interfaces/store.StoreCurrencyDTO/page.mdx)[]","description":"The supported currency codes of the store.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the store currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the store currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"is_default","type":"`boolean`","description":"Whether the currency is the default one for the store.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"store_id","type":"`string`","description":"The store ID associated with the currency.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string`","description":"The created date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string`","description":"The updated date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`null` \\| `string`","description":"The deleted date of the currency","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"default_sales_channel_id","type":"`string`","description":"The associated default sales channel's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_region_id","type":"`string`","description":"The associated default region's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"default_location_id","type":"`string`","description":"The associated default location's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createDefaultStoreStep"/>
|
||||
+1
-1
@@ -26,4 +26,4 @@ const data = deleteFilesStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteFilesStepInput","type":"[DeleteFilesStepInput](../../../../types/core_flows.DeleteFilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteFilesStepInput","type":"`string`[]","description":"The IDs of the files to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteFilesStep"/>
|
||||
<TypeList types={[{"name":"DeleteFilesStepInput","type":"[DeleteFilesStepInput](../../../../types/core_flows.DeleteFilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the files to delete.","expandable":false,"children":[{"name":"DeleteFilesStepInput","type":"`string`[]","description":"The IDs of the files to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteFilesStep"/>
|
||||
+1
-1
@@ -32,7 +32,7 @@ const data = uploadFilesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UploadFilesStepInput","type":"[UploadFilesStepInput](../../../../types/core_flows.UploadFilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"files","type":"`object`[]","description":"The files to upload.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"filename","type":"`string`","description":"The name of the file.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"mimeType","type":"`string`","description":"The MIME type of the file.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"content","type":"`string`","description":"The content of the file. For images, for example, \nuse base64 encoding. For CSV files, use the CSV content.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"access","type":"`\"public\"` \\| `\"private\"`","description":"The access level of the file. Use `public` for the file that\ncan be accessed by anyone. For example, for images that are displayed\non the storefront. Use `private` for files that are only accessible\nby authenticated users. For example, for CSV files used to\nimport data.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="uploadFilesStep"/>
|
||||
<TypeList types={[{"name":"UploadFilesStepInput","type":"[UploadFilesStepInput](../../../../types/core_flows.UploadFilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to upload files.","expandable":false,"children":[{"name":"files","type":"`object`[]","description":"The files to upload.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"filename","type":"`string`","description":"The name of the file.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"mimeType","type":"`string`","description":"The MIME type of the file.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"content","type":"`string`","description":"The content of the file. For images, for example, \nuse base64 encoding. For CSV files, use the CSV content.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"access","type":"`\"public\"` \\| `\"private\"`","description":"The access level of the file. Use `public` for the file that\ncan be accessed by anyone. For example, for images that are displayed\non the storefront. Use `private` for files that are only accessible\nby authenticated users. For example, for CSV files used to\nimport data.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="uploadFilesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ const data = calculateShippingOptionsPricesStep([{
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CalculateShippingOptionsPriceStepInput","type":"[CalculateShippingOptionsPriceStepInput](../../../../types/core_flows.CalculateShippingOptionsPriceStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The ID of the fulfillment provider.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"optionData","type":"`Record<string, unknown>`","description":"The `data` property of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The shipping method's `data` property with custom data passed from the frontend.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"[CartPropsForFulfillment](../../../../../fulfillment/types/fulfillment.CartPropsForFulfillment/page.mdx) & `object`","description":"The calculation context needed for the associated fulfillment provider to calculate the price of a shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"id\"`]","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"shipping_address\"`]","description":"The cart's shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"items\"`] & `object`","description":"The cart's items","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"variant","type":"`object`","description":"The item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"product","type":"`object`","description":"The item's product.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"from_location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The location that the items will be shipped from.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_sets","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)[]","description":"Fulfillment sets for the location","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"The creation date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"The update date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`string` \\| `Date` \\| `null`","description":"The deletion date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address","type":"[StockLocationAddressDTO](../../../../../fulfillment/types/fulfillment.StockLocationAddressDTO/page.mdx)","description":"The address of the stock location.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="calculateShippingOptionsPricesStep"/>
|
||||
<TypeList types={[{"name":"CalculateShippingOptionsPriceStepInput","type":"[CalculateShippingOptionsPriceStepInput](../../../../types/core_flows.CalculateShippingOptionsPriceStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to calculate the prices for one or more shipping options.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The ID of the fulfillment provider.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"optionData","type":"`Record<string, unknown>`","description":"The `data` property of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`Record<string, unknown>`","description":"The shipping method's `data` property with custom data passed from the frontend.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"[CartPropsForFulfillment](../../../../../fulfillment/types/fulfillment.CartPropsForFulfillment/page.mdx) & `object`","description":"The calculation context needed for the associated fulfillment provider to calculate the price of a shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"id\"`]","description":"The cart's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_address","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"shipping_address\"`]","description":"The cart's shipping address.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"items","type":"[CartDTO](../../../../../fulfillment/interfaces/fulfillment.CartDTO/page.mdx)[`\"items\"`] & `object`","description":"The cart's items","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"variant","type":"`object`","description":"The item's variant.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"product","type":"`object`","description":"The item's product.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"from_location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The location that the items will be shipped from.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_sets","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)[]","description":"Fulfillment sets for the location","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"created_at","type":"`string` \\| `Date`","description":"The creation date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"updated_at","type":"`string` \\| `Date`","description":"The update date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"deleted_at","type":"`string` \\| `Date` \\| `null`","description":"The deletion date of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address","type":"[StockLocationAddressDTO](../../../../../fulfillment/types/fulfillment.StockLocationAddressDTO/page.mdx)","description":"The address of the stock location.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="calculateShippingOptionsPricesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+2
-2
@@ -22,7 +22,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createFulfillmentSets({
|
||||
"name": "Anjali",
|
||||
"name": "Chloe",
|
||||
"type": "{value}"
|
||||
})
|
||||
}
|
||||
@@ -32,7 +32,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateFulfillmentSetsStepInput","type":"[CreateFulfillmentSetsStepInput](../../../../types/core_flows.CreateFulfillmentSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the fulfillment set.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the fulfillment set.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zones","type":"Omit<[CreateServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateServiceZoneDTO/page.mdx), \"fulfillment_set_id\">[]","description":"The service zones associated with the fulfillment set.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"geo_zones","type":"(Omit<[CreateCountryGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCountryGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateProvinceGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateProvinceGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateCityGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCityGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateZipGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateZipGeoZoneDTO/page.mdx), \"service_zone_id\">)[]","description":"The geo zones associated with the service zone.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createFulfillmentSets"/>
|
||||
<TypeList types={[{"name":"CreateFulfillmentSetsStepInput","type":"[CreateFulfillmentSetsStepInput](../../../../types/core_flows.CreateFulfillmentSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create one or more fulfillment sets.","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the fulfillment set.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the fulfillment set.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zones","type":"Omit<[CreateServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateServiceZoneDTO/page.mdx), \"fulfillment_set_id\">[]","description":"The service zones associated with the fulfillment set.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"geo_zones","type":"(Omit<[CreateCountryGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCountryGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateProvinceGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateProvinceGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateCityGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCityGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateZipGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateZipGeoZoneDTO/page.mdx), \"service_zone_id\">)[]","description":"The geo zones associated with the service zone.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createFulfillmentSets"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+2
-2
@@ -42,8 +42,8 @@ const data = createFulfillmentStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateFulfillmentDTO","type":"[CreateFulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivery_address","type":"Omit<[CreateFulfillmentAddressDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentAddressDTO/page.mdx), \"fulfillment_id\">","description":"The address associated with the fulfillment. It's used for delivery.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company","type":"`null` \\| `string`","description":"The company of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The first line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The second line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The ISO 2 character country code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"items","type":"Omit<[CreateFulfillmentItemDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentItemDTO/page.mdx), \"fulfillment_id\">[]","description":"The items associated with the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string`","description":"The SKU of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"`number`","description":"The quantity of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"barcode","type":"`string`","description":"The barcode of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"line_item_id","type":"`null` \\| `string`","description":"The associated line item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"inventory_item_id","type":"`null` \\| `string`","description":"The associated inventory item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The associated location's data.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulLine truncated
|
||||
<TypeList types={[{"name":"CreateFulfillmentDTO","type":"[CreateFulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment to be created.","expandable":false,"children":[{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivery_address","type":"Omit<[CreateFulfillmentAddressDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentAddressDTO/page.mdx), \"fulfillment_id\">","description":"The address associated with the fulfillment. It's used for delivery.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company","type":"`null` \\| `string`","description":"The company of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The first line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The second line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The ISO 2 character country code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"items","type":"Omit<[CreateFulfillmentItemDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentItemDTO/page.mdx), \"fulfillment_id\">[]","description":"The items associated with the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string`","description":"The SKU of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"`number`","description":"The quantity of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"barcode","type":"`string`","description":"The barcode of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"line_item_id","type":"`null` \\| `string`","description":"The associated line item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"inventory_item_id","type":"`null` \\| `string`","description":"The associated inventory item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The associated location's data.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":falLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The fuLine truncated
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`stringLine truncated
|
||||
+2
-2
@@ -42,8 +42,8 @@ const data = createReturnFulfillmentStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateFulfillmentDTO","type":"[CreateFulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivery_address","type":"Omit<[CreateFulfillmentAddressDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentAddressDTO/page.mdx), \"fulfillment_id\">","description":"The address associated with the fulfillment. It's used for delivery.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company","type":"`null` \\| `string`","description":"The company of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The first line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The second line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The ISO 2 character country code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"items","type":"Omit<[CreateFulfillmentItemDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentItemDTO/page.mdx), \"fulfillment_id\">[]","description":"The items associated with the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string`","description":"The SKU of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"`number`","description":"The quantity of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"barcode","type":"`string`","description":"The barcode of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"line_item_id","type":"`null` \\| `string`","description":"The associated line item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"inventory_item_id","type":"`null` \\| `string`","description":"The associated inventory item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The associated location's data.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulLine truncated
|
||||
<TypeList types={[{"name":"CreateFulfillmentDTO","type":"[CreateFulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment to be created.","expandable":false,"children":[{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivery_address","type":"Omit<[CreateFulfillmentAddressDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentAddressDTO/page.mdx), \"fulfillment_id\">","description":"The address associated with the fulfillment. It's used for delivery.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"company","type":"`null` \\| `string`","description":"The company of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`null` \\| `string`","description":"The first name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`null` \\| `string`","description":"The last name of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_1","type":"`null` \\| `string`","description":"The first line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"address_2","type":"`null` \\| `string`","description":"The second line of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"city","type":"`null` \\| `string`","description":"The city of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"country_code","type":"`null` \\| `string`","description":"The ISO 2 character country code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"province","type":"`null` \\| `string`","description":"The province of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"postal_code","type":"`null` \\| `string`","description":"The postal code of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`null` \\| `string`","description":"The phone of the fulfillment address.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"items","type":"Omit<[CreateFulfillmentItemDTO](../../../../../fulfillment/interfaces/fulfillment.CreateFulfillmentItemDTO/page.mdx), \"fulfillment_id\">[]","description":"The items associated with the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"title","type":"`string`","description":"The title of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"sku","type":"`string`","description":"The SKU of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"quantity","type":"`number`","description":"The quantity of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"barcode","type":"`string`","description":"The barcode of the fulfillment item.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"line_item_id","type":"`null` \\| `string`","description":"The associated line item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"inventory_item_id","type":"`null` \\| `string`","description":"The associated inventory item's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"location","type":"[StockLocationDTO](../../../../../fulfillment/types/fulfillment.StockLocationDTO/page.mdx)","description":"The associated location's data.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the stock location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`Record<string, unknown>` \\| `null`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"address_id","type":"`string`","description":"The associated address's ID.","optional":false,"defaultValue":"","expandable":falLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The fuLine truncated
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`stringLine truncated
|
||||
+2
-2
@@ -22,7 +22,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createServiceZonesStep({
|
||||
"name": "Fannie",
|
||||
"name": "Trisha",
|
||||
"fulfillment_set_id": "{value}"
|
||||
})
|
||||
}
|
||||
@@ -32,7 +32,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateServiceZonesStepInput","type":"[CreateServiceZonesStepInput](../../../../types/core_flows.CreateServiceZonesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The associated fulfillment set's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"geo_zones","type":"(Omit<[CreateCountryGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCountryGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateProvinceGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateProvinceGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateCityGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCityGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateZipGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateZipGeoZoneDTO/page.mdx), \"service_zone_id\">)[]","description":"The geo zones associated with the service zone.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createServiceZonesStep"/>
|
||||
<TypeList types={[{"name":"CreateServiceZonesStepInput","type":"[CreateServiceZonesStepInput](../../../../types/core_flows.CreateServiceZonesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The service zones to create.","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The associated fulfillment set's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"geo_zones","type":"(Omit<[CreateCountryGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCountryGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateProvinceGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateProvinceGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateCityGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateCityGeoZoneDTO/page.mdx), \"service_zone_id\"> \\| Omit<[CreateZipGeoZoneDTO](../../../../../fulfillment/interfaces/fulfillment.CreateZipGeoZoneDTO/page.mdx), \"service_zone_id\">)[]","description":"The geo zones associated with the service zone.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createServiceZonesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+2
-2
@@ -24,7 +24,7 @@ const myWorkflow = createWorkflow(
|
||||
const data = createShippingOptionRulesStep({
|
||||
"data": [{
|
||||
"attribute": "{value}",
|
||||
"operator": "lt",
|
||||
"operator": "nin",
|
||||
"value": "{value}",
|
||||
"shipping_option_id": "{value}"
|
||||
}]
|
||||
@@ -36,7 +36,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"AddFulfillmentShippingOptionRulesWorkflowDTO","type":"[AddFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.AddFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"data","type":"[CreateShippingOptionRuleDTO](../../../../../fulfillment/interfaces/fulfillment.CreateShippingOptionRuleDTO/page.mdx)[]","description":"The shipping option rules to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"attribute","type":"`string`","description":"The attribute of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"operator","type":"[RuleOperatorType](../../../../../fulfillment/types/fulfillment.RuleOperatorType/page.mdx)","description":"The operator of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`string` \\| `string`[]","description":"The value(s) of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingOptionRulesStep"/>
|
||||
<TypeList types={[{"name":"AddFulfillmentShippingOptionRulesWorkflowDTO","type":"[AddFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.AddFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"The data to create shipping option rules.","expandable":false,"children":[{"name":"data","type":"[CreateShippingOptionRuleDTO](../../../../../fulfillment/interfaces/fulfillment.CreateShippingOptionRuleDTO/page.mdx)[]","description":"The shipping option rules to create.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"attribute","type":"`string`","description":"The attribute of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"operator","type":"[RuleOperatorType](../../../../../fulfillment/types/fulfillment.RuleOperatorType/page.mdx)","description":"The operator of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`string` \\| `string`[]","description":"The value(s) of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingOptionRulesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-4
@@ -22,10 +22,10 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createShippingOptionsPriceSetsStep({
|
||||
"id": "id_BLA6ZcHiwdWyP",
|
||||
"id": "id_16APDWtw9O",
|
||||
"prices": [{
|
||||
"currency_code": "vuv",
|
||||
"amount": 14
|
||||
"currency_code": "npr",
|
||||
"amount": 2
|
||||
}]
|
||||
})
|
||||
}
|
||||
@@ -35,7 +35,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateShippingOptionsPriceSetsStepInput","type":"[CreateShippingOptionsPriceSetsStepInput](../../../../types/core_flows.CreateShippingOptionsPriceSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"prices","type":"([ShippingOptionsPriceCurrencyCode](../../../../interfaces/core_flows.ShippingOptionsPriceCurrencyCode/page.mdx) \\| `ShippingOptionsPriceRegionId`)[]","description":"The prices to create for the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"The currency code of the price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rules","type":"[PriceRule](../../../../../pricing_models/variables/pricing_models.PriceRule/page.mdx)[]","description":"The rules of the price.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"[IsDmlEntity]","type":"`boolean`","description":"","optional":false,"defaultValue":"true","expandable":false,"children":[]},{"name":"name","type":"[InferDmlEntityNameFromConfig](../../../../../types/DmlTypes/types/types.DmlTypes.InferDmlEntityNameFromConfig/page.mdx)<TConfig>","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"schema","type":"Schema","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingOptionsPriceSetsStep"/>
|
||||
<TypeList types={[{"name":"CreateShippingOptionsPriceSetsStepInput","type":"[CreateShippingOptionsPriceSetsStepInput](../../../../types/core_flows.CreateShippingOptionsPriceSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create price sets for shipping options.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"prices","type":"([ShippingOptionsPriceCurrencyCode](../../../../interfaces/core_flows.ShippingOptionsPriceCurrencyCode/page.mdx) \\| `ShippingOptionsPriceRegionId`)[]","description":"The prices to create for the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"currency_code","type":"`string`","description":"The currency code of the price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"rules","type":"[PriceRule](../../../../../pricing_models/variables/pricing_models.PriceRule/page.mdx)[]","description":"The rules of the price.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"[IsDmlEntity]","type":"`boolean`","description":"","optional":false,"defaultValue":"true","expandable":false,"children":[]},{"name":"name","type":"[InferDmlEntityNameFromConfig](../../../../../types/DmlTypes/types/types.DmlTypes.InferDmlEntityNameFromConfig/page.mdx)<TConfig>","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"schema","type":"Schema","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingOptionsPriceSetsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+2
-2
@@ -22,7 +22,7 @@ const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = createShippingProfilesStep({
|
||||
"name": "Missouri"
|
||||
"name": "Amalia"
|
||||
})
|
||||
}
|
||||
)
|
||||
@@ -31,7 +31,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"CreateShippingProfilesStepInput","type":"[CreateShippingProfilesStepInput](../../../../types/core_flows.CreateShippingProfilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping profile.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingProfilesStep"/>
|
||||
<TypeList types={[{"name":"CreateShippingProfilesStepInput","type":"[CreateShippingProfilesStepInput](../../../../types/core_flows.CreateShippingProfilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The shipping profiles to create.","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping profile.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="createShippingProfilesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteFulfillmentSetsStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteFulfillmentSetsStep({})
|
||||
const data = deleteFulfillmentSetsStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteFulfillmentSetsStepInput","type":"[DeleteFulfillmentSetsStepInput](../../../../types/core_flows.DeleteFulfillmentSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteFulfillmentSetsStepInput","type":"`string`[]","description":"The IDs of the fulfillment sets to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteFulfillmentSetsStep"/>
|
||||
<TypeList types={[{"name":"DeleteFulfillmentSetsStepInput","type":"[DeleteFulfillmentSetsStepInput](../../../../types/core_flows.DeleteFulfillmentSetsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the fulfillment sets to delete.","expandable":false,"children":[{"name":"DeleteFulfillmentSetsStepInput","type":"`string`[]","description":"The IDs of the fulfillment sets to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteFulfillmentSetsStep"/>
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { deleteServiceZonesStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteServiceZonesStep({})
|
||||
const data = deleteServiceZonesStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,4 +31,4 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteServiceZonesStepInput","type":"[DeleteServiceZonesStepInput](../../../../types/core_flows.DeleteServiceZonesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteServiceZonesStepInput","type":"`string`[]","description":"The IDs of the service zones to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteServiceZonesStep"/>
|
||||
<TypeList types={[{"name":"DeleteServiceZonesStepInput","type":"[DeleteServiceZonesStepInput](../../../../types/core_flows.DeleteServiceZonesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the service zones to delete.","expandable":false,"children":[{"name":"DeleteServiceZonesStepInput","type":"`string`[]","description":"The IDs of the service zones to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteServiceZonesStep"/>
|
||||
+2
-2
@@ -23,7 +23,7 @@ const myWorkflow = createWorkflow(
|
||||
() => {
|
||||
const data = deleteShippingOptionRulesStep({
|
||||
"ids": [
|
||||
"id_6JzwNsLgSgpH20FiTH"
|
||||
"id_FZwve8086P"
|
||||
]
|
||||
})
|
||||
}
|
||||
@@ -33,7 +33,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"RemoveFulfillmentShippingOptionRulesWorkflowDTO","type":"[RemoveFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.RemoveFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"ids","type":"`string`[]","description":"The IDs of the shipping option rules to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionRulesStep"/>
|
||||
<TypeList types={[{"name":"RemoveFulfillmentShippingOptionRulesWorkflowDTO","type":"[RemoveFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.RemoveFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"The data to delete shipping option rules.","expandable":false,"children":[{"name":"ids","type":"`string`[]","description":"The IDs of the shipping option rules to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionRulesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+5
-3
@@ -21,7 +21,9 @@ import { deleteShippingOptionsStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = deleteShippingOptionsStep({})
|
||||
const data = deleteShippingOptionsStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,8 +31,8 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"DeleteShippingOptionsStepInput","type":"[DeleteShippingOptionsStepInput](../../../../types/core_flows.DeleteShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteShippingOptionsStepInput","type":"`string`[]","description":"The IDs of the shipping options to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionsStep"/>
|
||||
<TypeList types={[{"name":"DeleteShippingOptionsStepInput","type":"[DeleteShippingOptionsStepInput](../../../../types/core_flows.DeleteShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The IDs of the shipping options to delete.","expandable":false,"children":[{"name":"DeleteShippingOptionsStepInput","type":"`string`[]","description":"The IDs of the shipping options to delete.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"DeleteEntityInput","type":"[DeleteEntityInput](../../../../../modules_sdk/types/modules_sdk.DeleteEntityInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"DeleteEntityInput","type":"`object`","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionsStep"/>
|
||||
<TypeList types={[{"name":"DeleteEntityInput","type":"[DeleteEntityInput](../../../../../modules_sdk/types/modules_sdk.DeleteEntityInput/page.mdx)","optional":false,"defaultValue":"","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","expandable":false,"children":[{"name":"DeleteEntityInput","type":"`object`","description":"The details of a data model's record whose linked records should be deleted. Usually used after the\ndata model's record is deleted.\n\nThe key is the data model's name. Its value is an object that has the ID of the data model's record.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="deleteShippingOptionsStep"/>
|
||||
+1
-1
@@ -33,4 +33,4 @@ const data = setShippingOptionsPricesStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"SetShippingOptionsPricesStepInput","type":"[SetShippingOptionsPricesStepInput](../../../../types/core_flows.SetShippingOptionsPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"prices","type":"[UpdateShippingOptionPriceRecord](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionPriceRecord/page.mdx)[]","description":"The prices of the shipping option.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the price record.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"rules","type":"[PriceRule](../../../../../pricing_models/variables/pricing_models.PriceRule/page.mdx)[]","description":"The rules of the price.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"[IsDmlEntity]","type":"`boolean`","description":"","optional":false,"defaultValue":"true","expandable":false,"children":[]},{"name":"name","type":"[InferDmlEntityNameFromConfig](../../../../../types/DmlTypes/types/types.DmlTypes.InferDmlEntityNameFromConfig/page.mdx)<TConfig>","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"schema","type":"Schema","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"region_id","type":"`string`","description":"The ID of the region that this price applies in.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="setShippingOptionsPricesStep"/>
|
||||
<TypeList types={[{"name":"SetShippingOptionsPricesStepInput","type":"[SetShippingOptionsPricesStepInput](../../../../types/core_flows.SetShippingOptionsPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to set the prices of a shipping option.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"prices","type":"[UpdateShippingOptionPriceRecord](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionPriceRecord/page.mdx)[]","description":"The prices of the shipping option.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the price record.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The currency code of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"`number`","description":"The amount of the price.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"rules","type":"[PriceRule](../../../../../pricing_models/variables/pricing_models.PriceRule/page.mdx)[]","description":"The rules of the price.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"[IsDmlEntity]","type":"`boolean`","description":"","optional":false,"defaultValue":"true","expandable":false,"children":[]},{"name":"name","type":"[InferDmlEntityNameFromConfig](../../../../../types/DmlTypes/types/types.DmlTypes.InferDmlEntityNameFromConfig/page.mdx)<TConfig>","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"schema","type":"Schema","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"region_id","type":"`string`","description":"The ID of the region that this price applies in.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="setShippingOptionsPricesStep"/>
|
||||
+1
-1
@@ -29,4 +29,4 @@ const data = updateFulfillmentStep({
|
||||
|
||||
## Output
|
||||
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The fuLine truncated
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`stringLine truncated
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateShippingOptionRulesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateFulfillmentShippingOptionRulesWorkflowDTO","type":"[UpdateFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.UpdateFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"data","type":"[UpdateShippingOptionRuleDTO](../../../../../fulfillment/interfaces/fulfillment.UpdateShippingOptionRuleDTO/page.mdx)[]","description":"The shipping option rules to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"attribute","type":"`string`","description":"The attribute of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"operator","type":"[RuleOperatorType](../../../../../fulfillment/types/fulfillment.RuleOperatorType/page.mdx)","description":"The operator of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`string` \\| `string`[]","description":"The value(s) of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`string`","description":"The associated shipping option's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateShippingOptionRulesStep"/>
|
||||
<TypeList types={[{"name":"UpdateFulfillmentShippingOptionRulesWorkflowDTO","type":"[UpdateFulfillmentShippingOptionRulesWorkflowDTO](../../../../../types/types/types.UpdateFulfillmentShippingOptionRulesWorkflowDTO/page.mdx)","optional":false,"defaultValue":"","description":"The data to update shipping option rules.","expandable":false,"children":[{"name":"data","type":"[UpdateShippingOptionRuleDTO](../../../../../fulfillment/interfaces/fulfillment.UpdateShippingOptionRuleDTO/page.mdx)[]","description":"The shipping option rules to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option rule.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"attribute","type":"`string`","description":"The attribute of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"operator","type":"[RuleOperatorType](../../../../../fulfillment/types/fulfillment.RuleOperatorType/page.mdx)","description":"The operator of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`string` \\| `string`[]","description":"The value(s) of the shipping option rule.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`string`","description":"The associated shipping option's ID.","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="updateShippingOptionRulesStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -29,7 +29,7 @@ const data = updateShippingProfilesStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpdateShippingProfilesStepInput","type":"[UpdateShippingProfilesStepInput](../../../../types/core_flows.UpdateShippingProfilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"update","type":"[UpdateShippingProfileDTO](../../../../../fulfillment/interfaces/fulfillment.UpdateShippingProfileDTO/page.mdx)","description":"The data to update in the shipping profiles.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"selector","type":"[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx)","description":"The filters to select the shipping profiles to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"id","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"The IDs to filter the shipping profiles by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"Filter the shipping profiles by their name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"Filter the shipping profiles by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_options","type":"[FilterableShippingOptionProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingOptionProps/page.mdx)","description":"The filters to apply on the retrieved shipping options.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.Line truncated
|
||||
<TypeList types={[{"name":"UpdateShippingProfilesStepInput","type":"[UpdateShippingProfilesStepInput](../../../../types/core_flows.UpdateShippingProfilesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to update a shipping profile.","expandable":false,"children":[{"name":"update","type":"[UpdateShippingProfileDTO](../../../../../fulfillment/interfaces/fulfillment.UpdateShippingProfileDTO/page.mdx)","description":"The data to update in the shipping profiles.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The name of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string`","description":"The type of the shipping profile.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"selector","type":"[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx)","description":"The filters to select the shipping profiles to update.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"$and","type":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"id","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"The IDs to filter the shipping profiles by.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"Filter the shipping profiles by their name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"`string` \\| `string`[] \\| [OperatorMap](../../../../../fulfillment/types/fulfillment.OperatorMap/page.mdx)<string \\| string[]>","description":"Filter the shipping profiles by their type.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_options","type":"[FilterableShippingOptionProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingOptionProps/page.mdx)","description":"The filters to apply on the retrieved shipping options.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"$or","type":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interfaces/fulfillment.BaseFilterable/page.mdx)<[FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/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":"([FilterableShippingProfileProps](../../../../../fulfillment/interfaces/fulfillment.FilterableShippingProfileProps/page.mdx) \\| [BaseFilterable](../../../../../fulfillment/interLine truncated
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+4
-2
@@ -21,7 +21,9 @@ import { upsertShippingOptionsStep } from "@medusajs/medusa/core-flows"
|
||||
const myWorkflow = createWorkflow(
|
||||
"my-workflow",
|
||||
() => {
|
||||
const data = upsertShippingOptionsStep({})
|
||||
const data = upsertShippingOptionsStep([
|
||||
"{value}"
|
||||
])
|
||||
}
|
||||
)
|
||||
```
|
||||
@@ -29,7 +31,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"UpsertShippingOptionsStepInput","type":"[UpsertShippingOptionsStepInput](../../../../types/core_flows.UpsertShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"UpsertShippingOptionsStepInput","type":"Omit<[CreateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.CreateShippingOptionsWorkflowInput/page.mdx) \\| [UpdateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionsWorkflowInput/page.mdx), \"prices\">[]","description":"The data to create or update shipping options.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="upsertShippingOptionsStep"/>
|
||||
<TypeList types={[{"name":"UpsertShippingOptionsStepInput","type":"[UpsertShippingOptionsStepInput](../../../../types/core_flows.UpsertShippingOptionsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to create or update shipping options.","expandable":false,"children":[{"name":"UpsertShippingOptionsStepInput","type":"Omit<[CreateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.CreateShippingOptionsWorkflowInput/page.mdx) \\| [UpdateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionsWorkflowInput/page.mdx), \"prices\">[]","description":"The data to create or update shipping options.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="upsertShippingOptionsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
+1
-1
@@ -41,4 +41,4 @@ const data = validateShippingOptionPricesStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"ValidateShippingOptionPricesStepInput","type":"[ValidateShippingOptionPricesStepInput](../../../../types/core_flows.ValidateShippingOptionPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"ValidateShippingOptionPricesStepInput","type":"([CreateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.CreateShippingOptionsWorkflowInput/page.mdx) \\| [UpdateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionsWorkflowInput/page.mdx))[]","description":"The data to validate shipping option prices.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateShippingOptionPricesStep"/>
|
||||
<TypeList types={[{"name":"ValidateShippingOptionPricesStepInput","type":"[ValidateShippingOptionPricesStepInput](../../../../types/core_flows.ValidateShippingOptionPricesStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to validate shipping option prices.","expandable":false,"children":[{"name":"ValidateShippingOptionPricesStepInput","type":"([CreateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.CreateShippingOptionsWorkflowInput/page.mdx) \\| [UpdateShippingOptionsWorkflowInput](../../../../../types/WorkflowTypes/FulfillmentWorkflow/types/types.WorkflowTypes.FulfillmentWorkflow.UpdateShippingOptionsWorkflowInput/page.mdx))[]","description":"The data to validate shipping option prices.","optional":false,"defaultValue":"","expandable":false,"children":[]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="validateShippingOptionPricesStep"/>
|
||||
+1
-1
@@ -148,7 +148,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"createShipmentWorkflow","steps":[{"type":"step","name":"validateShipmentStep","description":"This step validates that a shipment can be created for a fulfillment.\nIf the shipment has already been created, the fulfillment has been canceled,\nor the fulfillment does not have a shipping option, the step throws an error.","link":"../../../Steps_Fulfillment/functions/core_flows.Fulfillment.Steps_Fulfillment.validateShipmentStep/page.mdx","depth":1},{"type":"workflow","name":"updateFulfillmentWorkflow","description":"This workflow updates a fulfillment. It's used by other workflows that update a \nfulfillment, such as [markFulfillmentAsDeliveredWorkflow](../core_flows.Fulfillment.Workflows_Fulfillment.markFulfillmentAsDeliveredWorkflow/page.mdx).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to\nupdate a fulfillment within your custom flows.","link":"../core_flows.Fulfillment.Workflows_Fulfillment.updateFulfillmentWorkflow/page.mdx","depth":2}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"createShipmentWorkflow","steps":[{"type":"step","name":"validateShipmentStep","description":"This step validates that a shipment can be created for a fulfillment.\nIf the shipment has already been created, the fulfillment has been canceled,\nor the fulfillment does not have a shipping option, the step throws an error.","link":"../../../Steps_Fulfillment/functions/core_flows.Fulfillment.Steps_Fulfillment.validateShipmentStep/page.mdx","depth":1},{"type":"workflow","name":"updateFulfillmentWorkflow","description":"Update a fulfillment.","link":"../core_flows.Fulfillment.Workflows_Fulfillment.updateFulfillmentWorkflow/page.mdx","depth":2}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+1
-1
@@ -128,7 +128,7 @@ const myWorkflow = createWorkflow(
|
||||
|
||||
## Steps
|
||||
|
||||
<WorkflowDiagram workflow={{"name":"markFulfillmentAsDeliveredWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"validateFulfillmentDeliverabilityStep","description":"This step validates that a fulfillment can be marked delivered.\nIf the fulfillment has already been canceled or delivered, the step will throw an error.\n\n:::note\n\nYou can retrieve a fulfillment's details using [Query](https://docs.medusajs.com/learn/fundamentals/module-links/query),\nor [useQueryGraphStep](https://docs.medusajs.com/resources/references/medusa-workflows/steps/useQueryGraphStep).\n\n:::","link":"../core_flows.Fulfillment.Workflows_Fulfillment.validateFulfillmentDeliverabilityStep/page.mdx","depth":2},{"type":"workflow","name":"updateFulfillmentWorkflow","description":"This workflow updates a fulfillment. It's used by other workflows that update a \nfulfillment, such as [markFulfillmentAsDeliveredWorkflow](./page.mdx).\n\nYou can use this workflow within your own customizations or custom workflows, allowing you to\nupdate a fulfillment within your custom flows.","link":"../core_flows.Fulfillment.Workflows_Fulfillment.updateFulfillmentWorkflow/page.mdx","depth":3}]}} />
|
||||
<WorkflowDiagram workflow={{"name":"markFulfillmentAsDeliveredWorkflow","steps":[{"type":"step","name":"useRemoteQueryStep","description":"This step fetches data across modules using the remote query.\n\nLearn more in the [Remote Query documentation](https://docs.medusajs.com/learn/fundamentals/module-links/query).\n\n:::note\n\nThis step is deprecated. Use [useQueryGraphStep](../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useQueryGraphStep/page.mdx) instead.\n\n:::","link":"../../../../Common/Steps_Common/functions/core_flows.Common.Steps_Common.useRemoteQueryStep/page.mdx","depth":1},{"type":"step","name":"validateFulfillmentDeliverabilityStep","description":"This step validates that a fulfillment can be marked delivered.\nIf the fulfillment has already been canceled or delivered, the step will throw an error.\n\n:::note\n\nYou can retrieve a fulfillment's details using [Query](https://docs.medusajs.com/learn/fundamentals/module-links/query),\nor [useQueryGraphStep](https://docs.medusajs.com/resources/references/medusa-workflows/steps/useQueryGraphStep).\n\n:::","link":"../core_flows.Fulfillment.Workflows_Fulfillment.validateFulfillmentDeliverabilityStep/page.mdx","depth":2},{"type":"workflow","name":"updateFulfillmentWorkflow","description":"Update a fulfillment.","link":"../core_flows.Fulfillment.Workflows_Fulfillment.updateFulfillmentWorkflow/page.mdx","depth":3}]}} />
|
||||
|
||||
## Input
|
||||
|
||||
|
||||
+1
-1
@@ -33,4 +33,4 @@ const data = validateFulfillmentDeliverabilityStep({
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`string`","description":"The fuLine truncated
|
||||
<TypeList types={[{"name":"FulfillmentDTO","type":"[FulfillmentDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentDTO/page.mdx)","optional":false,"defaultValue":"","description":"The fulfillment details.","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The associated location's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"packed_at","type":"`null` \\| `Date`","description":"The date the fulfillment was packed.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipped_at","type":"`null` \\| `Date`","description":"The date the fulfillment was shipped.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"delivered_at","type":"`null` \\| `Date`","description":"The date the fulfillment was delivered.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"canceled_at","type":"`null` \\| `Date`","description":"The date the fulfillment was canceled.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the fulfillment provider to process\nthe fulfillment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_id","type":"`null` \\| `string`","description":"The associated shipping option's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option","type":"`null` \\| [ShippingOptionDTO](../../../../../fulfillment/interfaces/fulfillment.ShippingOptionDTO/page.mdx)","description":"The associated shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the shipping option.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"price_type","type":"[ShippingOptionPriceType](../../../../../fulfillment/types/fulfillment.ShippingOptionPriceType/page.mdx)","description":"The type of the shipping option's price.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone_id","type":"`string`","description":"The associated service zone's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_profile_id","type":"`string`","description":"The associated shipping profile's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"provider_id","type":"`string`","description":"The associated fulfillment provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"shipping_option_type_id","type":"`null` \\| `string`","description":"The associated shipping option type's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"data","type":"`null` \\| `Record<string, unknown>`","description":"The data necessary for the associated fulfillment provider to process the shipping option\nand, later, its associated fulfillments.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"service_zone","type":"[ServiceZoneDTO](../../../../../fulfillment/interfaces/fulfillment.ServiceZoneDTO/page.mdx)","description":"The associated service zone.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"name","type":"`string`","description":"The name of the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"metadata","type":"`null` \\| `Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set","type":"[FulfillmentSetDTO](../../../../../fulfillment/interfaces/fulfillment.FulfillmentSetDTO/page.mdx)","description":"The fulfillment set assoiated with the service zone.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"fulfillment_set_id","type":"`stringLine truncated
|
||||
+1
-1
@@ -30,7 +30,7 @@ const data = adjustInventoryLevelsStep([
|
||||
|
||||
## Input
|
||||
|
||||
<TypeList types={[{"name":"AdjustInventoryLevelsStepInput","type":"[AdjustInventoryLevelsStepInput](../../../../types/core_flows.AdjustInventoryLevelsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the associated inventory level.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The ID of the associated location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"adjustment","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity to adjust the inventory level by.\nIf positive, the quantity will be added to the stocked quantity.\nIf negative, the quantity will be subtracted from the stocked quantity.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="adjustInventoryLevelsStep"/>
|
||||
<TypeList types={[{"name":"AdjustInventoryLevelsStepInput","type":"[AdjustInventoryLevelsStepInput](../../../../types/core_flows.AdjustInventoryLevelsStepInput/page.mdx)","optional":false,"defaultValue":"","description":"The data to adjust the inventory levels.","expandable":false,"children":[{"name":"inventory_item_id","type":"`string`","description":"The ID of the associated inventory level.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"location_id","type":"`string`","description":"The ID of the associated location.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"adjustment","type":"[BigNumberInput](../../../../../types/types/types.BigNumberInput/page.mdx)","description":"The quantity to adjust the inventory level by.\nIf positive, the quantity will be added to the stocked quantity.\nIf negative, the quantity will be subtracted from the stocked quantity.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../../../../types/types/types.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]}]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" openedLevel={1} sectionTitle="adjustInventoryLevelsStep"/>
|
||||
|
||||
## Output
|
||||
|
||||
|
||||
Loaded 100 of 484 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user