For the complete documentation index, see llms.txt. This page is also available as Markdown.

Get installation JWT token

Return a JWT token used to authenticate requests against the specified WordPress installation, including its MCP (Model Context Protocol) endpoint.

Get installation JWT token

get

Return a JWT token used to authenticate requests against the specified WordPress installation, including its MCP (Model Context Protocol) endpoint.

Provide the WordPress installation (software) identifier in the path. It can be obtained from GET /api/hosting/v1/wordpress/installations (the id field).

Authorizations
AuthorizationstringRequired

API Token authentication

Path parameters
usernamestringRequiredExample: u123456789
softwarestringRequired

WordPress installation (software) identifier

Example: 1232456789Pattern: ^[0-9]+$
Responses
200

Success response

application/json
tokenstringOptional

Signed JWT used to authenticate requests against the WordPress installation

Example: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9
expires_inintegerOptional

Token lifetime in seconds from the moment it was issued

Example: 3600
expires_atstring · date-time · nullableOptional

Date-time at which the token expires, or null when not provided

Example: 2024-06-05T12:08:00Z
mcp_urlstring · nullableOptional

MCP (Model Context Protocol) endpoint URL for the WordPress installation, or null when not provided

Example: https://example.com/wp-json/hostinger/mcp
get/api/hosting/v1/accounts/{username}/wordpress/{software}/jwt-token
GET /api/hosting/v1/accounts/{username}/wordpress/{software}/jwt-token HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9",
  "expires_in": 3600,
  "expires_at": "2024-06-05T12:08:00Z",
  "mcp_url": "https://example.com/wp-json/hostinger/mcp"
}

Last updated

Was this helpful?