BackstageClient.taxRegistrations
BackstageClient.taxRegistrations in @ticketlayer/backstage.
@ticketlayer/backstage / BackstageClient / taxRegistrations
taxRegistrations: {
create: (request: {
address?: string | null;
jurisdiction: string;
legalName?: string | null;
partyId: string;
registeredFrom: string;
registeredUntil?: string | null;
registrationNumber?: string | null;
stripeProviderId?: string | null;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>;
delete: (registrationId: string, requestOptions?: RequestOptions) => Promise<boolean>;
list: (options?: {
partyId?: string;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}[]>;
update: (registrationId: string, request: {
address?: string | null;
legalName?: string | null;
registeredUntil?: string | null;
registrationNumber?: string | null;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>;
};Defined in: client.ts:11667
Tax Registrations methods
create()#
create: (request: {
address?: string | null;
jurisdiction: string;
legalName?: string | null;
partyId: string;
registeredFrom: string;
registeredUntil?: string | null;
registrationNumber?: string | null;
stripeProviderId?: string | null;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>;Add a tax registration Register a party for tax in a jurisdiction from a date. In GB the VAT number is required and UK VAT is computed natively; anywhere else the scheme is Stripe Tax, calculated in the organisation's Stripe account (or the one stripeProviderId names), where the registration must also be held. Overlapping another registration of the same party there is 409 TAX_REGISTRATION_OVERLAPS. From the start date the party's sales there carry tax: tickets of its events, fees it earns, goods it sells. Needs accounts.update on the account (every account for the organisation).
Parameters#
| Parameter | Type | Description |
|---|---|---|
request | { address?: string | null; jurisdiction: string; legalName?: string | null; partyId: string; registeredFrom: string; registeredUntil?: string | null; registrationNumber?: string | null; stripeProviderId?: string | null; } | - |
request.address? | string | null | Description The address tax documents print. A UK VAT invoice needs it |
request.jurisdiction? | string | Description ISO 3166-1 alpha-2 (or a country name), or US-XX for a US state Example GB |
request.legalName? | string | null | Description The name tax documents print; the account name when absent |
request.partyId? | string | Description The account registered, or the organisation id Example acc_abc123 |
request.registeredFrom? | string | Description YYYY-MM-DD: the first day sales are taxed Example 2026-04-01 |
request.registeredUntil? | string | null | Description YYYY-MM-DD: the last day, inclusive Example null |
request.registrationNumber? | string | null | Description The VAT number; required in GB, where it is checked and normalised (GB and 9 or 12 digits) Example GB 123 4567 89 |
request.stripeProviderId? | string | null | Description Outside the UK: the Stripe payment provider whose account calculates the tax, where the registration is held at Stripe. Absent: the organisation's own Stripe account, else its Ticketlayer Pay account |
requestOptions? | RequestOptions | - |
Returns#
Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>
Operation Id#
createTaxRegistration
delete()#
delete: (registrationId: string, requestOptions?: RequestOptions) => Promise<boolean>;Remove a tax registration made in error Remove a registration that has taxed nothing. One that has taxed an order line is 409 TAX_REGISTRATION_IN_USE: end it instead. Needs accounts.update on its account.
Parameters#
| Parameter | Type |
|---|---|
registrationId | string |
requestOptions? | RequestOptions |
Returns#
Promise<boolean>
Operation Id#
deleteTaxRegistration
list()#
list: (options?: {
partyId?: string;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}[]>;List tax registrations The organisation's tax registrations: each party's registration for tax in a jurisdiction, effective-dated. A party with none in force charges no tax. Filter by partyId. Needs accounts.read; without a filter, the registrations of the accounts it covers.
Parameters#
| Parameter | Type |
|---|---|
options? | { partyId?: string; } |
options.partyId? | string |
requestOptions? | RequestOptions |
Returns#
Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}[]>
Operation Id#
listTaxRegistrations
update()#
update: (registrationId: string, request: {
address?: string | null;
legalName?: string | null;
registeredUntil?: string | null;
registrationNumber?: string | null;
}, requestOptions?: RequestOptions) => Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>;Correct or end a tax registration Correct the registration number, legal name or address, or end the registration (registeredUntil). Documents already issued keep what they printed. Its party, jurisdiction and start date are what sales were taxed by and do not change: end it and add another. Needs accounts.update on its account.
Parameters#
| Parameter | Type | Description |
|---|---|---|
registrationId | string | - |
request | { address?: string | null; legalName?: string | null; registeredUntil?: string | null; registrationNumber?: string | null; } | - |
request.address? | string | null | - |
request.legalName? | string | null | - |
request.registeredUntil? | string | null | Description YYYY-MM-DD: end the registration; null reopens it |
request.registrationNumber? | string | null | - |
requestOptions? | RequestOptions | - |
Returns#
Promise<{
address: string | null;
createdAt: string;
id: string;
jurisdiction: string;
legalName: string | null;
partyId: string;
registeredFrom: string;
registeredUntil: string | null;
registrationNumber: string | null;
scheme: "uk_vat" | "stripe_tax";
stripeProviderId: string | null;
updatedAt: string;
}>
Operation Id#
updateTaxRegistration