Nhost · Example Payload

Nhost Token Refresh Example

Example request and response for exchanging a refresh token for a new session with a fresh access token.

GraphQLPostgreSQLAuthenticationFile StorageServerless FunctionsReal-TimeOpen-SourceFirebase AlternativeBackend-as-a-Service

Nhost Token Refresh Example is an example object payload from Nhost, with 4 top-level fields. It illustrates the shape of data this provider's APIs accept or return.

Top-level fields

titledescriptionrequestresponse

Example Payload

Raw ↑
{
  "title": "Nhost Refresh Token Exchange",
  "description": "Example request and response for exchanging a refresh token for a new session with a fresh access token.",
  "request": {
    "method": "POST",
    "url": "https://{subdomain}.auth.{region}.nhost.run/v1/token",
    "headers": {
      "Content-Type": "application/json"
    },
    "body": {
      "refreshToken": "a6f6e5c4-d3b2-4a1e-9f8d-7c6b5a4e3d2c"
    }
  },
  "response": {
    "status": 200,
    "headers": {
      "Content-Type": "application/json"
    },
    "body": {
      "accessToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.newtoken.signature",
      "accessTokenExpiresIn": 900,
      "refreshToken": "c8h8g7e6-f5d4-6c3g-1b0f-9e8d7c6b5a4e",
      "refreshTokenId": "d9i9h8f7-g6e5-7d4h-2c1g-0f9e8d7c6b5a",
      "user": {
        "id": "1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d",
        "email": "user@example.com",
        "displayName": "Jane Doe",
        "avatarUrl": "",
        "locale": "en",
        "emailVerified": true,
        "phoneNumber": null,
        "phoneNumberVerified": false,
        "defaultRole": "user",
        "allowedRoles": ["user", "me"],
        "isAnonymous": false,
        "activeMfaType": null,
        "createdAt": "2024-01-15T10:30:00Z",
        "updatedAt": "2024-06-01T08:00:00Z",
        "metadata": {}
      }
    }
  }
}

Work with this as data

Every example here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for examples

4 MCP tools reach this
  • find_examplesBrowse and filter every example in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This example
curl "https://apis.io/api/v1/examples/nhost-token-refresh-example"
All examples
curl "https://apis.io/api/v1/examples?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.