Skip to content
Get started

Retrieve a customer by ID

express.retrieve(strexpress_customer_id) -> ExpressRetrieveResponse
GET/v1/express/{expressCustomerId}

Retrieves a single customer by its unique customer ID. Returns the complete customer object with name, status, and timestamps.

ParametersExpand Collapse
express_customer_id: str

Unique Express customer identifier. Format: cus_{32-hex-chars}

ReturnsExpand Collapse
class ExpressRetrieveResponse:

An Express customer entity that groups users and studies

created_at: Optional[datetime]

Timestamp when the Express customer was created

formatdate-time
express_customer_id: str

Unique Express customer identifier. Format: cus_{32-hex-chars}

express_customer_name: str

Name of the Express customer

minLength1
is_active: bool

Whether the Express customer is currently active

updated_at: Optional[datetime]

Timestamp when the Express customer was last updated

formatdate-time
user_count: int

Number of users currently in this Express customer

minimum0
created_by_api_key_id: Optional[str]

UUID of the API key used to create this Express customer, for audit tracking

formatuuid
created_by_user_id: Optional[str]

User ID who created this Express customer via dashboard, null if created via API key

metadata: Optional[Dict[str, str]]

Custom key-value metadata for the Express customer. Maximum 50 pairs, keys up to 100 chars, values up to 1000 chars

Retrieve a customer by ID

import os
from avara import Avara

client = Avara(
    api_key=os.environ.get("AVARA_API_KEY"),  # This is the default and can be omitted
)
express = client.express.retrieve(
    "cus_1234567890abcdef1234567890abcdef",
)
print(express.created_at)
{
  "createdAt": "2024-01-15T09:00:00Z",
  "expressCustomerId": "cus_1234567890abcdef1234567890abcdef",
  "expressCustomerName": "City Medical Center - Radiology Department",
  "isActive": true,
  "updatedAt": "2024-03-15T14:20:00Z",
  "userCount": 15,
  "createdByApiKeyId": "550e8400-e29b-41d4-a716-446655440000",
  "createdByUserId": "usr_1234567890abcdef1234567890abcdef",
  "metadata": {
    "department": "radiology",
    "region": "northeast"
  }
}
Returns Examples
{
  "createdAt": "2024-01-15T09:00:00Z",
  "expressCustomerId": "cus_1234567890abcdef1234567890abcdef",
  "expressCustomerName": "City Medical Center - Radiology Department",
  "isActive": true,
  "updatedAt": "2024-03-15T14:20:00Z",
  "userCount": 15,
  "createdByApiKeyId": "550e8400-e29b-41d4-a716-446655440000",
  "createdByUserId": "usr_1234567890abcdef1234567890abcdef",
  "metadata": {
    "department": "radiology",
    "region": "northeast"
  }
}