Skip to main content
GET
/
checkout
/
guest
/
addresses
JavaScript
import HenrySDK from '@henrylabs/sdk';

const client = new HenrySDK({
  apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted
});

const addresses = await client.checkout.guest.addresses.list();

console.log(addresses.message);
{
  "success": true,
  "status": "<string>",
  "message": "<string>",
  "data": {
    "addresses": [
      {
        "fullName": "John Doe",
        "email": "[email protected]",
        "phoneNumber": "+1234567890",
        "addressLine1": "350 5th Ave",
        "countryCode": "US",
        "city": "New York",
        "stateOrProvince": "New York",
        "postalCode": "10001",
        "addressLine2": "Apt 1",
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "isDefault": true
      }
    ]
  }
}

Authorizations

x-api-key
string
header
required
x-access-token
string
header
required

Supabase access token for authentication.

Headers

x-user-id
string

Required when authenticating with API key

Response

Guest addresses retrieved successfully

success
boolean
required
status
string
required
message
string
required
data
object