The API block is our most powerful non-model block. You can encrypt API keys using the Secrets section, add a URL, add headers, and select an API method when using this block.

For a detailed breakdown on how this block works, see our Learning Respell YouTube series.

Method

The API Block allows you to call any API endpoint using the REST architecture. This means you can choose between a variety of methods that match your API endpoint.

Secrets

Secrets are where you can store any API Keys you need to call your API. Anything stored in secrets is encrypted and will not be shared when spells are published publicly.

URL

In the URL section, you can create a HTTP request. When you add inputs to your API block, they become available in the โ€œinputโ€ section as buttons. Similarly, any secrets become available as a button in the โ€œsecretsโ€ section. These buttons can be used as variable in the URL.

Headers

The headers section can be edited similar to the URL section. Any secrets or inputs added to the API block will be accessible in the editor. These buttons can be used as a variable.