Generate Tax Pack

This section outlines the detailed process of scheduling a job to generate a Tax Pack using the Phoenix API.

πŸ” Prerequisites: Obtaining the Client GUID

Before generating a tax pack, you'll need the client GUID. If you only have the client ID or need to look up client information, use the Clients API endpoint.

Retrieving Client Information

GET /clients

Base URL Example:

https://fslpresales.fslcgix-uat.co.uk/FSLPresales_PhoenixApi/clients

Query Parameters

You can filter clients using the following optional parameters:

ParameterTypeDescription
clientIdstringThe identifier for the CGiX Client (e.g., "CLIENT123")
companyIdstringThe identifier for the CGiX Company
externalIdstring (guid)External identifier for the request

Response Format

[
  {
    "clientGuid": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "clientId": "string",
    "clientName": "string",
    "sortName": "string",
    "clientTaxType": "UK_Individual",
    "companyId": "string",
    "isIncomeClient": true,
    "currencyIso": "string",
    "incomeTaxRateId": "string",
    "taxReportingPeriodName": "string",
    "isHmrcReportable": true,
    "incomeTypeName": "string",
    "incomeSubtypeName": "string",
    "taxIdentificationNumber": "string",
    "taxFormTypeName": "string",
    "taxFormDate": "2026-01-29T12:06:26.932Z",
    "relationshipStartDate": "2026-01-29T12:06:26.932Z",
    "dateOfBirth": "2026-01-29T12:06:26.932Z",
    "placeOfBirth": "string",
    "passport1CountryIso": "string",
    "passport2CountryIso": "string",
    "externalId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "externalProcessedDateTime": "2026-01-29T12:06:26.932Z",
    "clientTaxTypeDescription": "string",
    "taxYear": "2026-01-29T12:06:26.932Z",
    "dateOfExpiry": "2026-01-29T12:06:26.932Z",
    "clientNameFormatted": "string",
    "status": "string",
    "entityCountryIso": "string",
    "usTaxIdNumber": "string",
    "dateFormSigned": "2026-01-29T12:06:26.932Z",
    "dateOfDeath": "2026-01-29T12:06:26.932Z",
    "isProbate": true,

    "probate": {
      "clientGuid": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "clientId": "string"
    }
  }
]

πŸ‘¨β€βš–οΈ Understanding Probate Clients

When isProbate is true, the client represents the estate of a deceased individual

Probate Object Fields:

  • probate.clientGuid - The GUID of the probate client
  • probate.clientId - The client ID of the probate client

How Probate Works:

  1. When a client passes away, their dateOfDeath is recorded
  2. A new probate client is created to represent the estate with isProbate: true
  3. The probate object links back to the original deceased client
  4. Historical data remains with the original client
  5. New estate transactions are associated with the probate client
🚧

Important: When generating tax packs for probate clients, use the probate.clientGuid not the deceased client GUID. The probate client will not have an address so this will need to be added.



πŸ”§ 1. Creating the Request

Create a new request in Postman as follows:

  1. Ensure you have a valid access token retrieved via the authentication process.

  2. Change the HTTP verb from GET to POST

  3. Click on the Authorization tab and set the access token as the Bearer Token that was retrieved previously

    To learn how to obtain an authorization token, see Obtaining an Access Token

  4. Specify the URL to the /taxpacks/uk API endpoint. For example: https://fslpresales.fslcgix-uat.co.uk/FSLPresales_PhoenixApi/taxpacks/uk

  5. Navigate to the Body tab, selecting raw as the input type. Then choose JSON from the dropdown on the right hand side. Here the following text is required before making the API call:

{
  "clientGuid": "3fa85f64-5717-4562-b3fc-2c963f66afa6", //Unique identifier for the client - must exist in the database
  "reportingPeriod": "Annual", //Options: Annual, Interim, or other supported periods
  "startDate": "2026-01-28T15:02:46.268Z", //Start date of the tax pack reporting period
  "endDate": "2026-01-28T15:02:46.268Z", //End date of the tax pack reporting period
  "runAsReprint": true, //Set to true to generate as a reprint, false for original
  "showDuplicateWatermark": true, //Set to true to display watermark on duplicate copies
  "runAsLive": true, //Set to true for live execution, false for test/preview
  "calculationExecutionDetails": {
    "calculationToDate": "2026-01-28T15:02:46.268Z", //Date up to which calculations should run
    "clearCalculationToDateOnCompletion": true //Set to true to reset calculation date after completion
  }
}

πŸ“‹ Request Body Parameters

ParameterTypeRequiredDescription
clientGuidstring (GUID)YesValidated against clients which exist in the database. Must be a valid income client.
reportingPeriodstring (enum)YesThe reporting frequency (e.g., Annual, Interim). Must match the client's configured reporting period. Dual reporting periods are not supported.
startDatedatetimeYesBeginning of the tax pack period in ISO 8601 format. Must align with the client's reporting cycle.
endDatedatetimeYesEnd of the tax pack period in ISO 8601 format. Must align with the client's reporting cycle and match the date range for the specified reporting period.
runAsReprintbooleanNoWhen set to true, generates the tax pack as a reprint. Requires that a live report has been previously generated and transactions flagged as reported for this period.
showDuplicateWatermarkbooleanNoWhen set to true, displays a watermark indicating this is a duplicate copy.
runAsLivebooleanYesWhen set to true, executes as a live production run and flags transactions as reported. Set to false for testing or preview purposes.
calculationExecutionDetailsobjectNoContains calculation-specific settings.
calculationToDatedatetimeNoSpecifies the date up to which tax calculations should be performed.
clearCalculationToDateOnCompletionbooleanNoWhen set to true, resets the calculation date once the pack generation is complete.

🏒 Tax Pack Generation Per Address

🚧

Important: The system generates one separate tax pack report for each address associated with the client.

This means:

  • If a client has multiple addresses, multiple PDF reports will be generated (one per address)
  • Each report will be specific to the transactions and data associated with that particular address
  • All generated reports are bundled together in a single ZIP file for download
  • The address reference is used to identify and organize each report within the ZIP package

πŸ“ File Naming Convention

The tax pack file naming is controlled by the TaxPackFileNameConvention company profile setting. This setting can be configured at the company level to customize how tax pack files are named.

βš™οΈ Default Naming Convention

If the TaxPackFileNameConvention profile setting is not configured or is empty, the system uses the default format:

TaxRep_AddressRef_[TaxYearEndYear]_[Counter].pdf

Example: TaxRep_12345_2026_1.pdf

🎯 Custom Naming Convention Tokens

When configuring the TaxPackFileNameConvention company profile setting, the following tokens are available:

TokenDescriptionExample Output
ClientIDThe client's unique identifierCLIENT123
ReportingCountryISO country code of the reporting countryGB
CounterSequential number for multiple reports{0} (replaced with 1, 2, 3, etc.)
TaxYearEndYearYear when the tax year ends2026
TaxYearStartTax year start date in ddMMyyyy format01012025
TaxYearEndTax year end date in ddMMyyyy format31122025
CurrentDateGeneration timestamp in yyyyMMddHHmm format202601281430
AddressRefReference number of the address12345
AddressNameName of the address (if available)London_Office
AddressTypeType of address (spaces replaced with underscores)Registered_Office

πŸ’‘ Example Profile Setting Values

Here are some example values for the TaxPackFileNameConvention company profile setting:

  1. Basic with client and counter:

    ClientID_Counter_TaxYearEndYear
  2. Detailed with dates and country:

    ReportingCountry_ClientID_TaxYearStart_TaxYearEnd_AddressType_Counter
  3. With timestamp and address:

    ClientID_AddressRef_TaxYearEndYear_CurrentDate_Counter
  4. Using address name instead of reference:

    ClientID_AddressName_TaxYearEndYear_Counter

βœ… Validation Requirements

Before generating a tax pack, the following conditions must be met:

πŸ‘€ Client Validation

  • Client must exist: The clientGuid must correspond to an existing client in the database.
  • Income client only: Tax pack generation is only available for income clients. Non-income clients will be rejected.
  • Client address required: At least one address must exist for the client.

πŸ“… Reporting Period Validation

  • Reporting period must be valid: The reportingPeriod must be a supported enum value.
  • Date range must match: The startDate and endDate must align with the client's configured reporting cycle.
  • Dual reporting not supported: Clients with dual reporting periods cannot generate tax packs.

πŸ”„ Reprint Validation

When runAsReprint is set to true:

  • Prior live report required: A live report must have been previously generated for this client.
  • Reported transactions required: The client must have reported transactions for the specified period (endDate).
  • Reported income must be enabled: If the ReportedIncome company profile setting is disabled (set to 0), both runAsReprint and runAsLive must be set to false.

🎯 Live Report Validation

When runAsLive is set to true:

  • Reported income must be enabled: If the ReportedIncome company profile setting is disabled (set to 0), runAsLive must be set to false.
❗️

Important Notes

  • runAsLive: Setting this to true will mark transactions as reported and generate an official tax pack. Use false for review or testing purposes.
  • runAsReprint: Use this when regenerating a tax pack that has already been produced for the same period. A reprint can only be executed after a live report has been generated.
  • Date Format: All dates must be provided in ISO 8601 format with timezone information.
  • Calculation consistency: The client's calculation date should remain stable during report generation to ensure consistency.
  • Multiple addresses: If the client has multiple addresses, each address will generate its own PDF report, all packaged into a single ZIP file.
  • File naming: The naming convention is controlled by the TaxPackFileNameConvention company profile setting and can be customized per company


πŸš€ 2. Sending the Request

Click the Send button to send the prepared request.

πŸ“¬ 3. The Response Body

Request StatusDescription
Accepted βœ…The request has succeeded and the tax pack generation has been scheduled
Bad Request ❌Indication that there is a client-side error in how the request was formed
Unauthorized πŸ”’Indicates a lack of valid authentication
Not Found πŸ”The requested resource was not found on the server

πŸ“„ Response Format

This JSON response is returned when a tax pack generation request is successfully scheduled.

{
    "correlationGuid": "1f783e3f-e2b8-40d0-a0f7-c0b3b1830fc9",
    "requestRoute": "/taxpacks/uk",
    "subscriptionMessage": "GenerateTaxPack",
    "requestStatus": "Accepted",
    "requestStatusDateTime": "2025-03-20T07:41:28.1347242+00:00",
    "requestStatusCheckRoute": "/notifications/1f783e3f-e2b8-40d0-a0f7-c0b3b1830fc9",
    "entityGuid": null,
    "entityCallbackRouteUri": null,
    "externalCorrelationId": null,
    "externalOperationId": null,
    "requestStatusComment": null,
    "callbackStatus": null,
    "callbackStatusDateTime": null,
    "callbackComment": null
}

Response Fields:

  • correlationGuid: Unique identifier for the scheduled job. Use this to check the status of the request and download the generated ZIP file containing all tax pack reports.
  • requestRoute: The API route where the tax pack request was initiated.
  • requestStatus: Current status of the request (e.g., Accepted, Processing, Completed).
  • requestStatusDateTime: Timestamp indicating when the request status was last updated.
  • requestStatusCheckRoute: API route to query the current status of the request.

To check the request status and access the generated tax pack ZIP file, follow the steps outlined in the Access Generated Tax Packs section.