swagger: '2.0' info: description: Provides the details on the purchase templates set for a particular program. version: '' title: VCA Purchase Template Details servers: - url: https://tts.apib2b.citi.com/tts/cards description: production gateway URL - url: https://tts.sandbox.apib2b.citi.com/tts/cards description: sandbox URL tags: [] schemes: - https consumes: - application/json produces: - application/json security: - clientCredentials: [] paths: /vca/v1/purchasetemplate/details: post: tags: null summary: Purchase Template Details description: '' operationId: getPurchaseTemplateDetails parameters: - name: Content-Type in: header description: Supports application/json required: true type: string - name: Authorization in: header description: sample required: true type: string - name: client_id in: query required: true description: >- This is your unique identifier shared during your CitiConnect API onboarding. This is the same `client_id` used for oauth token generation type: string - name: Country in: header description: sample required: true type: string - name: Region in: header description: sample required: true type: string - name: Req-Sys-Id in: header description: sample required: true type: string - in: body name: PurchaseTemplateInboundRequest description: PurchaseTemplateInboundRequest required: true schema: $ref: '#/definitions/PurchaseTemplateInboundRequest' responses: '200': description: >-
CodeDetails
PurchaseTemplateInboundSuccessResponse
schema: $ref: '#/definitions/PurchaseTemplateInboundSuccessResponse' '206': description: >-
PurchaseTemplateInboundPartialResponse
schema: $ref: '#/definitions/PurchaseTemplateInboundPartialResponse' '400': description: >-
ResponseCodes400
Error CodeError Description
ERS0060Client ID and/or Program Id is missing in Client Onboard Configuration setup. Contact Citi support.
MS0007There was a problem retrieving the purchase template details for Purchase Template ID: {templateId}
GRC0002Client ID is missing in the request header
GRC0003Invalid JSON Input
GRC0004Region ID is not available in the request
GRC0005Client Tracking ID is missing in the request header
GRC0010Client Tracking ID length should contain a min of 1 character and a max of 36 characters
GRC0011Client ID and/or Country and/or region id is missing in Client Onboard Configuration setup. Contact Citi support.
GRC0012Necessary header value is missing
GRC0016Country code is not available in the request
ERS0064No ID Provisioning data was found for the given Program Name: {programName}
ERS0065The required Program Name Field was empty
ERS0073Size of the programName exceeds max length
ERS0074Size of the templateId exceeds max length
ERS0075templateId should be a valid long value
schema: $ref: '#/definitions/ResponseCodes400' '500': description: >-
ResponseCode500
Error CodeError Description
GRC0001We have encountered an error and couldn't receive your request. Please try again, or contact Citi support if you have any further questions or comments
GRC0014We have encountered an error and couldn't receive your request. Please try again, or contact Citi support if you have any further questions or comments
MS0003There was a problem retrieving the funding source data for Program Name: {programName}
MS0004There was a problem retrieving ID provisioning data for Program Name: {programName}
MS0006 There was a problem retrieving the purchase template list for Program Name: {programName}
schema: $ref: '#/definitions/ResponseCode500' securityDefinitions: clientCredentials: description: >+ All CitiConnect APIs use the oAuth2 authentication scheme, which requires a bearer token to authenticate your API call. The Token URL includes the version of authentication used by this API. See the Citi Authentication API reference for information on requesting a token. type: oauth2 tokenUrl: https://tts.apib2b.citi.com/tts/cards/api/v1/oauth2/token flow: application scopes: null definitions: PurchaseTemplateInboundRequest: required: - programName properties: programName: type: string format: alphanumeric example: VCA Program NAM description: Company Name as defined in the virtual cards system maxLength: 200 templateId: type: array example: '["36091"]' description: >- Identifies the template that was setup in the VCA system.
The template setup in the VCA system defines which controls, custom data fields and MCC groupings can be used.

If templateId is included in the request, then purchase template details will be returned only for that purchase template. If templateId is not included in the request, then purchase template details will be returned for all that purchase templates under the VCA program items: type: string PurchaseTemplateInboundPartialResponse: properties: templates: type: array items: $ref: '#/definitions/Templates' Templates: required: - mccGrouping - mvcaEnabled - purchaseType - templateDescription - templateId - templateName - templateType properties: errors: type: array items: $ref: '#/definitions/RespCodes' templateId: type: string format: alphanumeric example: '36091' description: >- Identifies the template that was setup in the VCA system.
The template setup in the VCA system defines which controls, custom data fields and MCC groupings can be used. maxLength: 19 templateName: type: string format: alphanumeric example: Airline Purchases description: >- Identifies the template name that was setup in the VCA system and that should be used for this virtual card maxLength: 200 templateDescription: type: string format: alphanumeric example: Template for making arline purchases description: Description of the template. maxLength: 500 templateType: type: string format: alphanumeric example: PC description: Type of the template maxLength: 20 mvcaEnabled: type: string format: boolean example: 'true' description: Template enabled for mvca. purchaseType: type: array items: $ref: '#/definitions/PurchaseType' templateControl: type: array description: Spending control available in the template to use items: $ref: '#/definitions/TemplateControl' mccGrouping: type: string format: alphanumeric example: Airlines description: Name of Merchant Category Code grouping set on purchase template maxLength: 200 customReferenceData: type: array items: $ref: '#/definitions/CustomReferenceData' RespCodes: required: - errorCode - errorDescription properties: errorCode: type: string format: alphanumeric example: MS0007 description: which indicates the error code maxLength: 30 errorDescription: type: string format: alphanumeric example: >- There was a problem retrieving the purchase template list for Purchase Template ID: {templateId} description: which indicates the error description maxLength: 300 PurchaseType: required: - mcc - mccDescription properties: mcc: type: string format: alphanumeric example: '30001' description: Merchant Category Code used in the template maxLength: 4 mccDescription: type: string format: alphanumeric example: AMERICAN AIRLINES description: Merchant Category Code description maxLength: 200 TemplateControl: required: - controlCode - controlDescription properties: controlCode: type: string format: alphanumeric example: VL description: >- 2-character code of the template control name. Decides the type of control to use to create a purchase request.

Possible Values
AR (Amount range control)
CU (Curfew control)
GE (Geography control)
MA (Merchant amount control)
MI Merchant ID control)
TD (Time of day control)
TL (Transaction limit control)
VA (Validity period control)
VG (Aging velocity control)
VL (Velocity control) maxLength: 2 controlDescription: type: string format: alphanumeric example: Velocity description: Template control description maxLength: 50 CustomReferenceData: properties: customReferenceLabel: type: string format: alphanumeric example: Invoice Number description: Name of the custom field maxLength: 50 customReferenceValue: type: string format: alphanumeric example: '123456' description: Value of the custom field maxLength: 80 customReferenceMaxLength: type: string format: numeric example: '64' description: Maximum length of the custom field maxLength: 5 customReferenceDisplayType: type: string format: alphanumeric example: Text description: Display type of the custom field
Possible Values
Text
List maxLength: 4 customReferenceDataType: type: string format: alphanumeric example: Alphanumeric description: Data type of the custom field. maxLength: 50 customReferenceDataRequired: type: string format: alphanumeric example: 'N' description: >- Whether the custom field is required or not.
Possible Values
"Y" - Yes
"N" - No maxLength: 1 PurchaseTemplateInboundSuccessResponse: properties: templates: type: array items: $ref: '#/definitions/Templates2' Templates2: required: - mccGrouping - mvcaEnabled - purchaseType - templateDescription - templateId - templateName - templateType properties: templateId: type: string format: alphanumeric example: '36091' description: >- Identifies the template that was setup in the VCA system.
The template setup in the VCA system defines which controls, custom data fields and MCC groupings can be used. maxLength: 19 templateName: type: string format: alphanumeric example: Airline Purchases description: >- Identifies the template name that was setup in the VCA system and that should be used for this virtual card maxLength: 200 templateDescription: type: string format: alphanumeric example: Template for making arline purchases description: Description of the template. maxLength: 500 templateType: type: string format: alphanumeric example: PC description: Type of the template maxLength: 20 mvcaEnabled: type: string format: boolean example: 'true' description: Template enabled for mvca. purchaseType: type: array items: $ref: '#/definitions/PurchaseType' templateControl: type: array description: Spending control available in the template to use items: $ref: '#/definitions/TemplateControl' mccGrouping: type: string format: alphanumeric example: Airlines description: Name of Merchant Category Code grouping set on purchase template maxLength: 200 customReferenceData: type: array items: $ref: '#/definitions/CustomReferenceData' ResponseCodes400: properties: errors: type: array items: $ref: '#/definitions/ResponseCodes' ResponseCodes: required: - errorCode - errorDescription properties: errorCode: type: string format: alphanumeric example: ERS0065 description: which indicates the error code maxLength: 30 errorDescription: type: string format: alphanumeric example: The required Program Name Field was empty description: which indicates the error description maxLength: 300 ResponseCode500: properties: errors: type: array items: $ref: '#/definitions/ResponseCode' ResponseCode: properties: errorCode: type: string example: GRC0014 description: which indicates the error code errorDescription: type: string example: >- We have encountered an error and couldnot receive your request. Please try again, or contact Citi support if you have any further questions or comments description: which indicates the error description PurchaseTemplateErrorResponse: properties: errorMessage: type: array items: $ref: '#/definitions/ErrorResponseCode' ErrorResponseCode: properties: code: type: string format: alphanumeric description: which indicates the error code enum: - ERS0060 - MS0003 - MS0004 - GRC0001 - GRC0002 - GRC0003 - GRC0004 - GRC0005 - GRC0010 - GRC0011 - GRC0012 - GRC0014 - GRC0016 - MS0006 - MS0007 - ERS0064 - ERS0065 - ERS0073 - ERS0074 - ERS0075 description: type: string format: alphanumeric description: "\" The error description that corresponds to error code when there is any
error occurred while retrieving the trsansaction.
* `ERS0060`-Client ID and/or Program Id is missing in Client Onboard Configuration setup. Contact Citi support.\t
* `MS0003`-There was a problem retrieving the funding source data for Program Name: {programName}
* `MS0004`-There was a problem retrieving ID provisioning data for Program Name: {programName}\t
* `MS0006`- There was a problem retrieving the purchase template list for Program Name: {programName}
* `MS0007`-There was a problem retrieving the purchase template details for Purchase Template ID: {templateId}
* `GRC0001`-We have encountered an error and couldnt receive your request. Please try again, or contact Citi support if you have any further questions or comments
* `GRC0002`-Client ID is missing in the request header
* `GRC0003`-Invalid JSON Input
* `GRC0004`-Region ID is not available in the request\t
* `GRC0005`-Client Tracking ID is missing in the request header
* `GRC0010`-Client Tracking ID length should contain a min of 1 character and a max of 36 characters
* `GRC0011`-Client ID and/or Country and/or region id is missing in Client Onboard Configuration setup. Contact Citi support.
* `GRC0012`-Necessary header value is missing
* `GRC0014`-We have encountered an error and couldnt receive your request. Please try again, or contact Citi support if you have any further questions or comments
* `GRC0016`-Country code is not available in the request
* `ERS0064`-No ID Provisioning data was found for the given Program Name: {programName}
* `ERS0065`-The required Program Name Field was empty\t
* `ERS0073`-Size of the programName exceeds max length
* `ERS0074`-Size of the templateId exceeds max length
* `ERS0075`-templateId should be a valid long value" responses: '200': description: 200 OK '401': description: Unauthorised Access '403': description: Access Forbidden '500': description: Internal Server Error