The component contains the server action ConsumeAPI. The action takes an input parameter for the API URL as well as a records list of headers.
Create two entities:
1. API entity - with URL attribute to store the URL
2. Headers entity - Key and Value attributes to store details about the headers,
- API Identifier to create the relation between entities
When using the ConsumeAPI action, pass the desired URL and the Headers entity (filtered by the selected URL) to the action. Map the Key and Value attributes to the corresponding Headers input parameter.
The action will return the data and status code as outputs.