Skip to content

Commit

Permalink
Add metadata docs
Browse files Browse the repository at this point in the history
  • Loading branch information
pawelsierant committed Jul 10, 2024
1 parent 6feda04 commit 11fe5e5
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 3 deletions.
9 changes: 8 additions & 1 deletion docs/blocks/api_call_tool.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,11 @@ Headers | Valid JSON object of the headers to be sent with the request. i.e. `{"
Authorize | Whether to authorize the request with organization secret. | Default: `false`

---


## Parameters interpolation

You can use parameters in the `URL` and `headers` fields.

To use a parameter specified in `Parameters` field, enclose it within `{{}}`. For example, if you have a parameter named `id`, you can use it in the URL as `https://example.com/posts/{{id}}`.

In order to inject secret or [Metadata](../../docs/workflows/metadata) values, use `{{secrets.secret_name}}` or `{{metadata.metadata_name}}` respectively.
4 changes: 2 additions & 2 deletions docs/guides/05-api-call-tool.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: Api Call Tool
---
import {Video} from "/src/components/Video";
import { Video } from "/src/components/Video";

# Make an API Call to external APIs

Expand Down Expand Up @@ -51,7 +51,7 @@ As you can see, we have specified in the parameters that the [Api Call Tool](doc

:::tip

Similarly, you can use parameters in headers just like we did with the URL!
Similarly, you can use parameters in headers just like we did with the URL! Read more about it in the [Api Call Tool](docs/blocks/api_call_tool.mdx#Parameters-interpolation) documentation.

:::

Expand Down
15 changes: 15 additions & 0 deletions docs/workflows/metadata.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
title: Metadata
---

import { Video } from "/src/components/Video";

Workflow metadata is a powerful feature that allows you to store and retrieve information throught your workflow execution.
Metadata is stored in the pipeline run context and can be interpolated in [Api Call Tool](docs/blocks/api_call_tool.mdx#Parameters-interpolation) block
or in `X-Buildel-Context` header in [Api Call Tool](docs/blocks/api_call_tool.mdx) and [Webhook Output](docs/blocks/webhook_output.mdx) HTTP request.

You can send metadata via websocket or http request on pipeline start.

<Video type="video/webm" src="/mdx-assets/workflows/metadata/metadata_demo_07.webm"/>

---
Binary file not shown.

0 comments on commit 11fe5e5

Please sign in to comment.