[ ABORT TO HUD ]
SEQ. 1
SEQ. 2
Actions & API Integrations
Connecting GPTs to the Real World
Actions allow your Custom GPT to interact with external APIs. This turns a chatbot into an agent that can fetch live weather, create Jira tickets, or query a private database.
The OpenAPI Schema
To create an Action, provide an OpenAPI specification (Swagger). This JSON or YAML file describes your API's endpoints, parameters, and authentication methods.
openapi: 3.1.0
info:
title: Weather API
version: 1.0.0
paths:
/weather:
get:
summary: Get current weather
operationId: getCurrentWeather
parameters:
- name: location
in: query
required: true
schema:
type: string
Authentication Options
| Method | When to Use |
|---|---|
| None | Public APIs with no auth required |
| API Key | Simple bearer token or query param auth |
| OAuth 2.0 | User-specific access (Google, Slack, GitHub) |
Security Best Practice: Always require user confirmation before executing actions that modify data (POST, PUT, DELETE). Enforce this in the GPT instructions.
⌨ HANDS-ON LABSmoke-Test External Action Integration
⭐ +150 XPCustom GPT Actions connect to external REST APIs via OpenAPI specs. Test an authenticated action endpoint with curl.
1Send an authenticated request to an API endpoint with an Authorization Bearer header.
OBJECTIVE 1 / 1 — type "hint" if stuck
SYNAPSE VERIFICATION
QUERY 1 // 3
What format is required to define an Action in a Custom GPT?
A Python script
An OpenAPI (Swagger) schema in JSON or YAML
A Dockerfile
A GraphQL schema