Connect a Custom GPT to this WordPress site. ChatGPT chooses a template and fills mapped fields. WPsigner creates the document, emails the signer, and stores the signed PDF.
Admin path: WPsigner → Integrations → ChatGPT
- Go to WPsigner → Integrations → ChatGPT.
- Copy WordPress URL and AI API base (
/wp-json/insigner/v1/ai/). - Click Create an API key (WPsigner → Settings → API).
- Click Download OpenAPI spec.
- In ChatGPT: Create a GPT → Actions → Import that JSON.
- Authentication: API key headers
X-WPS-API-KeyandX-WPS-API-Secret. - Server URL:
https://your-site.example/wp-json/insigner/v1 - Paste the Custom GPT instructions from the WPsigner screen into the GPT.
Recommended GPT flow (same as the on-screen instructions):
- Call
list_templatesand pick a match. - Call
get_templateand readvariables. - Fill only those keys. Never invent field names.
- Call
preview_sendand show every field and signer. - Ask: “Send this document now?”
- Only if they say yes, call
send_documentwithsend=trueandconfirm=true.
Field tokens
Section titled “Field tokens”In Document Builder text or ChatGPT-generated content:
| Token | Becomes |
|---|---|
((name)) or {{name}} | Text field name |
((country)) | Text field country |
((date:start_date)) | Date field start_date |
((signature:1)) | Signature for signer #1 |
((signature:2)) | Signature for signer #2 |
PDF templates use the variable keys already set on each field in the WPsigner editor. Signature and initials are never prefilled.
REST (insigner/v1/ai)
Section titled “REST (insigner/v1/ai)”All routes use the same API-key auth as the rest of the REST API.
| Method | Path | Purpose |
|---|---|---|
GET | /ai/templates | List PDF and Document Builder templates (search, source=pdf|builder) |
GET | /ai/templates/{pdf|builder}/{id} | Template name, variables, signers needed |
POST | /ai/preview | Dry run. No document is written |
POST | /ai/send | Create from a PDF or builder template. Send only with confirm=true |
POST | /ai/from-content | Create from HTML/text with ((tokens)). Needs Document Builder. Same confirm rule |
GET | /ai/openapi | OpenAPI document (server URL set to this site) |
POST /ai/send with source=content uses the same path as /ai/from-content.
Troubleshooting
Section titled “Troubleshooting”| Issue | Solution |
|---|---|
| 401 / 403 | Full-access key, both headers, HTTPS |
confirm_required | Call preview, ask the user, then send with confirm=true |
document_builder_required | Install Document Builder for from-content |
| Empty or wrong fields | Use only keys from get_template. Do not invent names |
| GPT calls the wrong host | Server URL must be /wp-json/insigner/v1 on this site |
Next steps
Section titled “Next steps”- REST API — Keys, headers, and other endpoints
- Document Builder — Free-form contracts from ChatGPT text
- Form fields — Variable keys on PDF templates
- Templates API — Same templates the AI list reads