Skip to content
Get started

Create a new customer

ExpressCreateResponse express().create(ExpressCreateParamsparams, RequestOptionsrequestOptions = RequestOptions.none())
POST/v1/express

Creates a new customer with a unique identifier and name. Customers can be used to group and manage users, studies, and access permissions across the Avara platform.

ParametersExpand Collapse
ExpressCreateParams params
String expressCustomerName

Name of the Express customer to create

minLength1
Optional<Metadata> metadata

Custom key-value metadata for the Express customer. Maximum 50 pairs

ReturnsExpand Collapse
class ExpressCreateResponse:

An Express customer entity that groups users and studies

Optional<LocalDateTime> createdAt

Timestamp when the Express customer was created

formatdate-time
String expressCustomerId

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

String expressCustomerName

Name of the Express customer

minLength1
boolean isActive

Whether the Express customer is currently active

Optional<LocalDateTime> updatedAt

Timestamp when the Express customer was last updated

formatdate-time
long userCount

Number of users currently in this Express customer

minimum0
Optional<String> createdByApiKeyId

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

formatuuid
Optional<String> createdByUserId

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

Optional<Metadata> metadata

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

Create a new customer

package com.avara.example;

import com.avara.client.AvaraClient;
import com.avara.client.okhttp.AvaraOkHttpClient;
import com.avara.models.express.ExpressCreateParams;
import com.avara.models.express.ExpressCreateResponse;

public final class Main {
    private Main() {}

    public static void main(String[] args) {
        AvaraClient client = AvaraOkHttpClient.fromEnv();

        ExpressCreateParams params = ExpressCreateParams.builder()
            .expressCustomerName("City Medical Center - Radiology Department")
            .build();
        ExpressCreateResponse express = client.express().create(params);
    }
}
{
  "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"
  }
}