- You need an integration for a private or internal service (e.g., an internal deployment platform, a self-hosted tool)
- A first-party integration doesn’t exist yet for a public service you use
- You want to customize how agents interact with a service beyond what a first-party integration offers
How it works
A custom integration is a versioned package that tells the Guild runtime how to proxy HTTP requests to your service on behalf of agents. You define the endpoints, authentication method, and request/response schemas. Once published, agents can call your integration’s tools exactly like any first-party integration.Creating an integration
You can create integrations from the Guild UI or entirely from the CLI.- CLI
- UI
1. Create the integration
--public to make the integration visible to all users. By default it is private to your account.The command also creates a draft version automatically.2. Define operations
Add operations (endpoints) to your draft version. Each operation becomes a tool that agents can call.Add operations manually:3. Build and publish
1.0.0 after 1.1.0.4. Test
Test an operation against the live API:5. Connect credentials
--token for an interactive prompt. Use --owner to connect credentials for an organization account.6. Configure webhooks (optional)
Pass webhook event definitions as JSON when creating or updating the integration:Webhook format
If your integration receives inbound webhooks, your service must send a JSON body matching this format:action is null for events that don’t have sub-actions.
Each delivery must include these headers:
X-Guild-Webhook-Signature
A cryptographic signature that proves the delivery came from the integration and hasn’t been tampered with in transit. Guild rejects deliveries with a missing or invalid signature.
Generate it as follows:
- Take the raw request body as a string.
- Hash it using HMAC-SHA256 with the webhook secret key.
- Hex-encode the result and prefix it:
sha256=<hex-encoded hash> - Set that as the value of the
X-Guild-Webhook-Signatureheader.
X-Guild-Webhook-ID
A unique identifier for each individual delivery (e.g., a UUID generated fresh per request). Guild uses this to detect and discard duplicate deliveries, which is important because many systems retry failed webhook requests.
Content-Type
Must be set to application/json.
How the webhook URL is set up
When a user connects the integration and wants to receive webhook events, Guild generates a unique webhook URL for that connection. The user registers this URL with the external service (usually on its webhook configuration page) so the service knows where to send deliveries.
How the secret key is established
During that same registration, the external service typically reveals a secret key. The user copies the secret back into Guild, which stores it with the connection and uses it to verify the X-Guild-Webhook-Signature on every incoming delivery. Deliveries with a missing or mismatched signature are rejected.
Defining events
Each event has a name and an optional list of actions. For example:
| Event | Actions |
|---|---|
push | (none) |
pull_request | opened, closed, merged, reopened |