hosting

POST /v1/sites/{siteId}/mysql-access

Allow one IP address to reach MySQL as one database user.

Alle hosting-eindpunten

Authenticatie

Stuur een API-sleutel mee als bearer token. De sleutel moet over de permissie sites.panel_access beschikken; een sleutel zonder deze permissie wordt geweigerd met een 403 in plaats van een 404.

Dit eindpunt vereist geen organisatie-id. Uw sleutel identificeert al de organisatie waartoe deze behoort, en het antwoord is hierop afgestemd.

Probeer het

Vervang alles tussen punthaakjes door uw eigen waarden en de sleutelplaatsvervanger door een sleutel uit uw dashboard.

curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/mysql-access \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "user_id": <integer>, "address": <string> }'

Ingelogd? De API-console in je dashboard vult je echte organisatie-id en je eigen sleutel in, en voert het verzoek uit tegen de live API zodat je de daadwerkelijke respons kunt zien. Open dit eindpunt in de API-console

Details

Opens a database port to an address on the public internet, so this requires `sites.panel_access` — the same trust level as the file manager and the database credentials. Only a single IPv4 or IPv6 address is accepted: a hostname or a CIDR range is refused here rather than accepted by the vendor and silently matching nothing. The vendor takes up to 30 minutes to apply the rule.

Parameters

NaamTypeVerplichtWat dit is
siteId (path)UuidJaSite ID (UUIDv7).

Aanvraaglichaam

NaamTypeVerplichtWat dit is
user_idintegerJa⛔ The vendor's numeric user id, not the username. A request keyed by username is accepted and stores nothing.
addressstringJaA single IPv4 or IPv6 address. Ranges and hostnames are refused.

Reactie

NaamTypeVerplichtWat dit is
dataSiteMysqlAccessUser[]Ja

Fouten die dit eindpunt kan retourneren

401 · 403 · 404 · 422 · 429 · 503