{
  "opencollection": "1.0.0",
  "info": {
    "name": "Braintrust Acls Proxy API",
    "version": "1.0.0"
  },
  "request": {
    "auth": {
      "type": "bearer",
      "token": "{{bearerToken}}"
    }
  },
  "items": [
    {
      "info": {
        "name": "Proxy",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Proxy chat/completions",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/chat/completions",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Proxy a chat/completions request to the specified model, converting its format as needed. Will cache if temperature=0 or seed is set."
        },
        {
          "info": {
            "name": "Proxy completions",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/completions",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Proxy a completions request to the specified model, converting its format as needed. Will cache if temperature=0 or seed is set."
        },
        {
          "info": {
            "name": "Proxy a model to chat/completions or completions automatically",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/auto",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Proxy a request to either chat/completions or completions automatically based on the model. Will cache if temperature=0 or seed is set."
        },
        {
          "info": {
            "name": "Proxy embeddings",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/embeddings",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Proxy an embeddings request to the specified model, converting its format as needed. Will cache automatically."
        },
        {
          "info": {
            "name": "Create temporary credential",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/credentials",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Create a temporary credential which can access the proxy for a limited time. The temporary credential will be allowed to make requests on behalf of the Braintrust API key (or model provider API key) provided in the `Authorization` header. See [docs](/docs/deploy/ai-proxy#create-temporary-credentials) for code examples."
        },
        {
          "info": {
            "name": "Proxy any OpenAI request (fallback)",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.braintrust.dev/v1/proxy/:path+",
            "params": [
              {
                "name": "path+",
                "value": "",
                "type": "path",
                "description": "The path to proxy"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "bearer",
              "token": "{{bearerToken}}"
            }
          },
          "docs": "Any requests which do not match the above paths will be proxied directly to the OpenAI API."
        }
      ]
    }
  ],
  "bundled": true
}