Skip to content

Commit

Permalink
docs: fixes for core workflows reference (#11056)
Browse files Browse the repository at this point in the history
* 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
  • Loading branch information
shahednasser authored Jan 20, 2025
1 parent af350c3 commit 0d18d58
Showing 484 changed files with 1,172 additions and 1,128 deletions.
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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

Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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"/>
Original file line number Diff line number Diff line change
@@ -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

Original file line number Diff line number Diff line change
@@ -21,12 +21,14 @@ import { deleteApiKeysStep } from "@medusajs/medusa/core-flows"
const myWorkflow = createWorkflow(
"my-workflow",
() => {
const data = deleteApiKeysStep({})
const data = deleteApiKeysStep([
"{value}"
])
}
)
```


## 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"/>
Loading

0 comments on commit 0d18d58

Please sign in to comment.