public
POST /v1/wp/hosting-code
A plugin licence holder's hosting code, asked for from the plugin's wp-admin card.
Authentication
This endpoint takes no API key. Anything else it needs, such as a signed request, is described above.
This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.
Try it
Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.
curl -X POST https://api.zinndigital.com/v1/wp/hosting-code \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "email": <string>, "licence_id": <integer> }'Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console
Details
Called by a Zinn® plugin's wp-admin card (Page Builder Sandwich, Tranzly, Zinn® SEO), from inside the site, with the licence id and the licence holder's e-mail address that the plugin's licensing SDK holds. The code is returned only when that licence belongs to a buyer with that address; otherwise offer is null. Nothing is created here: codes are issued in the background for every paid licence holder. No credentials are needed because the code is useless to anyone else: checkout accepts it only for an account signed in with the same e-mail address. Rate limited per IP.
Request body
| Name | Type | Required | What it is |
|---|---|---|---|
email | string | Yes | — |
licence_id | integer | Yes | The store licence id. |
Response
| Name | Type | Required | What it is |
|---|---|---|---|
offer | HostingCodeOffer | null | Yes | — |
Errors this endpoint can return
422 · 429