openapi: 3.2.0 info: title: Billing Management Payment Terms API version: 1.0.0 description: Controller for managing payment terms. servers: - url: https://rls.congacloud.com/api/billing/v1 security: - Bearer: [] tags: - name: Payment Terms description: Controller for managing payment terms. paths: /payment-terms: get: tags: - Payment Terms summary: Retrieve the collection of payment term records description: Retrieves the collection of payment term records parameters: - name: filter in: query description: Optional filter parameters schema: type: array items: type: string - name: sort in: query description: Optional sort parameter schema: type: string - name: page in: query description: Page number schema: type: integer format: int32 default: 1 - name: limit in: query description: Number of items per page schema: type: integer format: int32 default: 50 - name: includes in: query description: Optional related entities to include schema: type: array items: type: string - name: fields in: query description: Optional name of the fields to include schema: type: array items: type: string - name: filterExpression in: query description: Optional filter expression schema: type: string responses: '200': description: OK content: text/plain: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: - Active: true IsDefault: true IsSystemCreated: false Description: This is a example payment term. Type: Compute StartBasis: Days StartValue: 30 FirstQuarterStartingMonth: January OffsetType1: End of the Month OffsetValue1: 0 OffsetType2: Days OffsetValue2: 10 OffsetType3: Start of the Quarter OffsetValue3: 0 Id: PaymentTermIdToUpdate Name: Updated Payment Term Name CreatedBy: null CreatedDate: '0001-01-01T00:00:00' ModifiedBy: null ModifiedDate: '0001-01-01T00:00:00' ExternalId: null ETag: null application/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: - Active: true IsDefault: true IsSystemCreated: false Description: This is a example payment term. Type: Compute StartBasis: Days StartValue: 30 FirstQuarterStartingMonth: January OffsetType1: End of the Month OffsetValue1: 0 OffsetType2: Days OffsetValue2: 10 OffsetType3: Start of the Quarter OffsetValue3: 0 Id: PaymentTermIdToUpdate Name: Updated Payment Term Name CreatedBy: null CreatedDate: '0001-01-01T00:00:00' ModifiedBy: null ModifiedDate: '0001-01-01T00:00:00' ExternalId: null ETag: null text/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: - Active: true IsDefault: true IsSystemCreated: false Description: This is a example payment term. Type: Compute StartBasis: Days StartValue: 30 FirstQuarterStartingMonth: January OffsetType1: End of the Month OffsetValue1: 0 OffsetType2: Days OffsetValue2: 10 OffsetType3: Start of the Quarter OffsetValue3: 0 Id: PaymentTermIdToUpdate Name: Updated Payment Term Name CreatedBy: null CreatedDate: '0001-01-01T00:00:00' ModifiedBy: null ModifiedDate: '0001-01-01T00:00:00' ExternalId: null ETag: null '204': description: No Content '500': description: Internal Server Error content: text/plain: schema: $ref: '#/components/schemas/ErrorApiResponse' application/json: schema: $ref: '#/components/schemas/ErrorApiResponse' text/json: schema: $ref: '#/components/schemas/ErrorApiResponse' patch: tags: - Payment Terms summary: Update payment term records description: Updates multiple payment term records and returns the updated payment term records with IDs. requestBody: description: The list of payment term records with updated data content: application/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Id\": \"PaymentTermIdToUpdate\",\n \"Name\": \"Updated Payment Term Name\"\n }\n]" text/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Id\": \"PaymentTermIdToUpdate\",\n \"Name\": \"Updated Payment Term Name\"\n }\n]" application/*+json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Id\": \"PaymentTermIdToUpdate\",\n \"Name\": \"Updated Payment Term Name\"\n }\n]" responses: '200': description: OK content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '207': description: Multi-Status content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '400': description: Bad Request content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '500': description: Internal Server Error content: text/plain: schema: $ref: '#/components/schemas/ErrorApiResponse' application/json: schema: $ref: '#/components/schemas/ErrorApiResponse' text/json: schema: $ref: '#/components/schemas/ErrorApiResponse' post: tags: - Payment Terms summary: Create payment term records description: Creates multiple payment term records and returns the created records with their IDs. requestBody: description: The list of payment term records content: application/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Name\": \"Payment Term Name\"\n }\n]" text/json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Name\": \"Payment Term Name\"\n }\n]" application/*+json: schema: type: array items: $ref: '#/components/schemas/PaymentTerm' example: "[\n {\n \"Active\": true,\n \"IsDefault\": true,\n \"IsSystemCreated\": false,\n \"Description\": \"This is a example payment term.\",\n \"Type\": \"Compute\",\n \"StartBasis\": \"Days\",\n \"StartValue\": 30,\n \"FirstQuarterStartingMonth\": \"January\",\n \"OffsetType1\": \"End of the Month\",\n \"OffsetValue1\": 0,\n \"OffsetType2\": \"Days\",\n \"OffsetValue2\": 10,\n \"OffsetType3\": \"Start of the Quarter\",\n \"OffsetValue3\": 0,\n \"Name\": \"Payment Term Name\"\n }\n]" responses: '201': description: Created content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '207': description: Multi-Status content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '400': description: Bad Request content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '500': description: Internal Server Error content: text/plain: schema: $ref: '#/components/schemas/ErrorApiResponse' application/json: schema: $ref: '#/components/schemas/ErrorApiResponse' text/json: schema: $ref: '#/components/schemas/ErrorApiResponse' /payment-terms/activate: patch: tags: - Payment Terms summary: Activate or deactivate a list of payment term records description: Toggles the Active flag for the ID's passed for payment term records. requestBody: description: Contains the list of payment term id and true/false to activate or deactivate the payment term. content: application/json: schema: type: array items: $ref: '#/components/schemas/PaymentTermToggleActiveRequest' text/json: schema: type: array items: $ref: '#/components/schemas/PaymentTermToggleActiveRequest' application/*+json: schema: type: array items: $ref: '#/components/schemas/PaymentTermToggleActiveRequest' responses: '200': description: OK content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '207': description: Multi-Status content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '400': description: Bad Request content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' /payment-terms/{id}: get: tags: - Payment Terms summary: Get a payment term record description: Retrieves a single payment term record by its identifier. parameters: - name: id in: path description: The identifier of the payment term required: true schema: type: string - name: includes in: query description: Optional related entities to include schema: type: array items: type: string responses: '200': description: OK content: text/plain: schema: $ref: '#/components/schemas/PaymentTerm' application/json: schema: $ref: '#/components/schemas/PaymentTerm' text/json: schema: $ref: '#/components/schemas/PaymentTerm' '404': description: Not Found content: text/plain: schema: $ref: '#/components/schemas/ErrorApiResponse' application/json: schema: $ref: '#/components/schemas/ErrorApiResponse' text/json: schema: $ref: '#/components/schemas/ErrorApiResponse' /payment-terms/{id}/default: put: tags: - Payment Terms summary: Mark the payment term record as default description: Marks the passed ID of the payment term record as org default. There can be only one default payment term record. parameters: - name: id in: path description: payment term id required: true schema: type: string responses: '200': description: OK content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '400': description: Bad Request content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' /payment-terms/{paymentTermId}/activate: patch: tags: - Payment Terms summary: Activate or deactivate a payment term record description: Toggles the Active flag for the ID passed for a payment term record. parameters: - name: paymentTermId in: path description: Payment term id required: true schema: type: string - name: active in: query description: Active flag value schema: type: boolean default: true responses: '200': description: OK content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' '400': description: Bad Request content: text/plain: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' application/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' text/json: schema: $ref: '#/components/schemas/BaseResponseBatchResponse' components: schemas: ErrorApiResponse: type: object properties: Errors: type: - array - 'null' items: $ref: '#/components/schemas/ApiError' additionalProperties: false ApiError: type: object properties: Source: type: - string - 'null' Title: type: - string - 'null' Detail: {} Help: type: - string - 'null' additionalProperties: false PaymentTermToggleActiveRequest: type: object properties: Active: type: boolean description: The flag contains whether the transaction has been successful or failed Id: type: - string - 'null' description: The unique identifier of the payment term additionalProperties: false description: 'Represents a request to toggle the active flag for a payment term. Contains the payment term identifier and the active status.' PaymentTerm: type: object properties: Id: type: - string - 'null' Name: type: - string - 'null' CreatedBy: $ref: '#/components/schemas/LookupObject' CreatedDate: type: string format: date-time ModifiedBy: $ref: '#/components/schemas/LookupObject' ModifiedDate: type: string format: date-time ExternalId: type: - string - 'null' ETag: type: - string - 'null' Active: type: - boolean - 'null' IsDefault: type: - boolean - 'null' IsSystemCreated: type: - boolean - 'null' Description: type: - string - 'null' Type: type: - string - 'null' StartBasis: type: - string - 'null' StartValue: type: - integer - 'null' format: int32 FirstQuarterStartingMonth: type: - string - 'null' OffsetType1: type: - string - 'null' OffsetValue1: type: - integer - 'null' format: int32 OffsetType2: type: - string - 'null' OffsetValue2: type: - integer - 'null' format: int32 OffsetType3: type: - string - 'null' OffsetValue3: type: - integer - 'null' format: int32 additionalProperties: {} BaseResponse: type: object properties: Id: type: - string - 'null' RecordIndex: type: integer format: int32 IsSuccess: type: boolean Errors: type: - array - 'null' items: type: string ErrorMessage: type: - string - 'null' deprecated: true additionalProperties: false BaseResponseBatchResponse: type: object properties: Summary: type: - string - 'null' Results: type: - array - 'null' items: $ref: '#/components/schemas/BaseResponse' additionalProperties: false LookupObject: type: object properties: Id: type: - string - 'null' Name: type: - string - 'null' additionalProperties: false securitySchemes: Bearer: type: apiKey description: Please insert JWT with Bearer into field name: Authorization in: header