Lune Docs Logo

Client accounts

Create a client account

HTTP POST to /v1/accounts/client
Request body

The account name.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account beneficiary. Leading and trailing spaces are removed.

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Response

Client accounts are designed for clients working with multi-tenancy applications.

Client accounts are created programmatically. The API key (created in live or test mode) determines whether the Client account is a live or test account.

Create a Client Account for each of your customers to segregate their API operations.

Use the special Lune-Account header to perform operations against a specific Client Account.

The Account's unique identifier

The Account's name

The unique identifier of the organisation this account belongs to

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account's type.

live
test

The account logo

Retirement beneficiary

This is the name that appears on future retirements that are made in this account. If none is present, the organisation beneficiary will be used instead.

Bundle portfolio id tied to the account.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Errors
This API operation can return the following errors:
HTTP status codeError code
400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found

List client accounts

HTTP GET to /v1/accounts/client
Query parameters

Pattern: ^\d+$

Maximum number of resources to return, between 1 and 100.

A cursor for use in pagination.

The cursor that points to the starting item of the next page of results. If not provided, the first page of results is returned.

Pattern: ^[a-zA-Z0-9_]{3,}$

Filter accounts based on name (case insensitive).

The value can appear at the beggining, middle or end on the actual account name.

Response

Whether or not there are more elements available after this set.

If false, this set comprises the end of the array.

Part of a paginated response.

The cursor value to be used as the after parameter for fetching the next page of results.

null if has_more is false.

An array of Client Account objects

Part of a paginated response.

Client accounts are designed for clients working with multi-tenancy applications.

Client accounts are created programmatically. The API key (created in live or test mode) determines whether the Client account is a live or test account.

Create a Client Account for each of your customers to segregate their API operations.

Use the special Lune-Account header to perform operations against a specific Client Account.

The Account's unique identifier

The Account's name

The unique identifier of the organisation this account belongs to

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account's type.

live
test

The account logo

Retirement beneficiary

This is the name that appears on future retirements that are made in this account. If none is present, the organisation beneficiary will be used instead.

Bundle portfolio id tied to the account.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Errors
This API operation can return the following errors:
HTTP status codeError code
400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found

Get a client account

HTTP GET to /v1/accounts/client/me
Response

Client accounts are designed for clients working with multi-tenancy applications.

Client accounts are created programmatically. The API key (created in live or test mode) determines whether the Client account is a live or test account.

Create a Client Account for each of your customers to segregate their API operations.

Use the special Lune-Account header to perform operations against a specific Client Account.

The Account's unique identifier

The Account's name

The unique identifier of the organisation this account belongs to

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account's type.

live
test

The account logo

Retirement beneficiary

This is the name that appears on future retirements that are made in this account. If none is present, the organisation beneficiary will be used instead.

Bundle portfolio id tied to the account.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Errors
This API operation can return the following errors:
HTTP status codeError code
400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found

Update a client account

HTTP PUT to /v1/accounts/client/{id}
Query parameters

The account's unique identifier

Request body

It's only possible to edit the name and beneficiary of an account.

Not providing the beneficiary property will result in clearing the existing value (if present).

The account name.

The account beneficiary. Leading and trailing spaces are removed.

The bundle portfolio unique identifier.

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

Either hidden or public. Controls the visibility of external pages such as sustainability and analytics pages. Default is hidden

public
hidden
Response

Client accounts are designed for clients working with multi-tenancy applications.

Client accounts are created programmatically. The API key (created in live or test mode) determines whether the Client account is a live or test account.

Create a Client Account for each of your customers to segregate their API operations.

Use the special Lune-Account header to perform operations against a specific Client Account.

The Account's unique identifier

The Account's name

The unique identifier of the organisation this account belongs to

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account's type.

live
test

The account logo

Retirement beneficiary

This is the name that appears on future retirements that are made in this account. If none is present, the organisation beneficiary will be used instead.

Bundle portfolio id tied to the account.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Errors
This API operation can return the following errors:
HTTP status codeError code
400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found

Partially update a client account

HTTP PATCH to /v1/accounts/client/{id}
Query parameters

The account's unique identifier

Request body

Providing null on a property will result in clearing the existing value (if present).

The account name.

The account beneficiary. Leading and trailing spaces are removed.

The bundle portfolio unique identifier.

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

Controls the visibility of external pages such as sustainability and analytics pages.

Defaults to hidden.

public
hidden
Response

Client accounts are designed for clients working with multi-tenancy applications.

Client accounts are created programmatically. The API key (created in live or test mode) determines whether the Client account is a live or test account.

Create a Client Account for each of your customers to segregate their API operations.

Use the special Lune-Account header to perform operations against a specific Client Account.

The Account's unique identifier

The Account's name

The unique identifier of the organisation this account belongs to

Pattern: ^[a-z0-9-_]+$

handle is a client defined URL-friendly string that identifies the account.

The handle is unique per organisation and account type.

The account's currency.

ISO 4217 3 character currency code.

Note: Lune does not support all currency codes.

GBP
EUR
USD
SEK
CHF

The account's type.

live
test

The account logo

Retirement beneficiary

This is the name that appears on future retirements that are made in this account. If none is present, the organisation beneficiary will be used instead.

Bundle portfolio id tied to the account.

Enum to control the visibility of external pages such as sustainability and analytics pages.

public
hidden
Errors
This API operation can return the following errors:
HTTP status codeError code
400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found
HTTP POST to /v1/accounts/client/{id}/logo
Query parameters

The account's unique identifier

Request body
  • Content type is multipart/form-data
  • Response

    Uploaded account logo URL

    Errors
    This API operation can return the following errors:
    HTTP status codeError code
    400
    api_version_invalid
    400
    bundle_selection_ratios_invalid
    400
    bundle_selection_bundle_invalid
    400
    order_value_invalid
    400
    bundle_id_invalid
    400
    id_invalid
    400
    distance_invalid
    400
    test_account_name_update_disallowed
    400
    bundle_selection_ratios_invalid_format
    400
    address_not_found