The OpenAI Provider supports querying GPT language models for prompt-based interactions.

Authentication

This provider requires authentication.

  • api_key: OpenAI Platform API Key (required: True, sensitive: True)
  • organization_id: OpenAI Platform Organization ID (required: False, sensitive: False)

In workflows

This provider can be used in workflows.

As “step” to query data, example:

steps:
    - name: Query openai
      provider: openai
      config: "{{ provider.my_provider_name }}"
      with:
        prompt: {value}  
        model: {value}  
        max_tokens: {value}  
        structured_output_format: {value}  

Check the following workflow examples:

Connecting with the Provider

To connect to OpenAI, you’ll need to obtain an API Key and (optionally) an Organization ID:

  1. Log in to your OpenAI account at OpenAI Platform.
  2. Go to the API Keys section.
  3. Click on Create new secret key to generate a key for Keep.
  4. (Optional) Retrieve your Organization ID under Organization settings if you’re part of multiple organizations.

Use the generated API key in the authentication section of your OpenAI Provider configuration.