OVPAY-416 - Added GET /contracts
This commit is contained in:
parent
ae2937d4c3
commit
98c4b3bd64
@ -6,14 +6,14 @@ info:
|
||||
servers:
|
||||
- url: https://api.integratielaag.nl/v1
|
||||
paths:
|
||||
/customers/{customerProfileId}/contracts/:
|
||||
/customers/{customerNumber}/contracts/:
|
||||
parameters:
|
||||
- in: path
|
||||
name: customerProfileId
|
||||
name: customerNumber
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: The id of the CustomerProfile.
|
||||
description: The customerNumber.
|
||||
get:
|
||||
summary: List all contracts for a certain customer profile.
|
||||
description: List all contracts for a certain customer profile.
|
||||
@ -135,6 +135,99 @@ paths:
|
||||
"contractNumber": "123456",
|
||||
},
|
||||
}
|
||||
/contracts:
|
||||
get:
|
||||
summary: Get all contracts.
|
||||
description: Get all contracts.
|
||||
tags:
|
||||
- Contract
|
||||
parameters:
|
||||
- in: query
|
||||
name: contractStatusId
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
type: integer
|
||||
explode: false
|
||||
required: false
|
||||
description: Filter on possible contract status. 1 = new, 2 = active, 3 = suspended, 4 = cancelled, 5 = terminated.
|
||||
- in: query
|
||||
name: billingDay
|
||||
schema:
|
||||
type: integer
|
||||
required: false
|
||||
description: Filter on billingDay.
|
||||
- in: query
|
||||
name: invoiceLimit
|
||||
schema:
|
||||
type: integer
|
||||
required: false
|
||||
description: Number of invoices to include in response body.
|
||||
responses:
|
||||
"200":
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/Contract"
|
||||
example:
|
||||
{
|
||||
"contracts":
|
||||
[
|
||||
{
|
||||
"contractId": "5a3876a1-e9a1-4278-8983-4679a8d583c2",
|
||||
"contractNumber": "D123456",
|
||||
"customerProfileId": "bfe6174e-52aa-4fd7-927b-7802256bc054",
|
||||
"orderId": "eb3d08f7-7feb-4f31-9f5b-daa634e51f48",
|
||||
"orderLineId": "52efbbfc-8c28-4016-9ece-dc3ef9a70bd8",
|
||||
"touchpointId": 2,
|
||||
"contractStatus":
|
||||
{ "contractStatusId": 2, "name": "active" },
|
||||
"productId": 1,
|
||||
"productName": "HTM Maand 20% korting",
|
||||
"termDuration": "P0Y1M0D",
|
||||
"billingDay": 15,
|
||||
"highestInvoiceTerm": 1,
|
||||
"xSpit": "1c345237-4d84-47f0-93c2-7b94338e3355",
|
||||
"highestContractInvoice":
|
||||
{
|
||||
"contractInvoiceId": "8699d72a-cf4d-4e6b-9e9c-549d837ca51f",
|
||||
"externalReference": "WEFACT-123456",
|
||||
"term": 1,
|
||||
"created": "2024-07-02 15:01:00.000",
|
||||
"updated": "2024-07-02 15:01:00.000",
|
||||
"state": "invoice_created",
|
||||
"data": "{json}",
|
||||
},
|
||||
},
|
||||
{
|
||||
"contractId": "f07253e6-c364-474c-a342-a10a4a7cf305",
|
||||
"contractNumber": "D123456",
|
||||
"customerProfileId": "bfe6174e-52aa-4fd7-927b-7802256bc054",
|
||||
"orderId": "945d43e6-516e-425b-8847-9aba41289acd",
|
||||
"orderLineId": "42f68042-908f-41f4-9d9b-4cab843ff0e8",
|
||||
"touchpointId": 2,
|
||||
"contractStatus":
|
||||
{ "contractStatusId": 1, "name": "new" },
|
||||
"productId": 1,
|
||||
"productName": "HTM Maand 20% korting",
|
||||
"termDuration": "P0Y1M0D",
|
||||
"billingDay": 15,
|
||||
"highestInvoiceTerm": 1,
|
||||
"xSpit": "1c345237-4d84-47f0-93c2-7b94338e3355",
|
||||
"highestContractInvoice":
|
||||
{
|
||||
"contractInvoiceId": "e2462347-6749-4841-b42a-cf8de19ec727",
|
||||
"externalReference": "WEFACT-123457",
|
||||
"term": 1,
|
||||
"created": "2024-07-02 15:01:00.000",
|
||||
"updated": "2024-07-02 15:01:00.000",
|
||||
"state": "invoice_created",
|
||||
"data": "{json}",
|
||||
},
|
||||
},
|
||||
],
|
||||
}
|
||||
/contracts/{contractId}:
|
||||
parameters:
|
||||
- in: path
|
||||
@ -502,28 +595,14 @@ paths:
|
||||
$ref: "#/components/schemas/ContractStatus"
|
||||
example:
|
||||
{
|
||||
"contractStatuses" : [
|
||||
{
|
||||
"contractStatusId" : 1,
|
||||
"name" : "new"
|
||||
},
|
||||
{
|
||||
"contractStatusId" : 2,
|
||||
"name" : "active"
|
||||
},
|
||||
{
|
||||
"contractStatusId" : 3,
|
||||
"name" : "suspended"
|
||||
},
|
||||
{
|
||||
"contractStatusId" : 4,
|
||||
"name" : "cancelled"
|
||||
},
|
||||
{
|
||||
"contractStatusId" : 5,
|
||||
"name" : "terminated"
|
||||
}
|
||||
]
|
||||
"contractStatuses":
|
||||
[
|
||||
{ "contractStatusId": 1, "name": "new" },
|
||||
{ "contractStatusId": 2, "name": "active" },
|
||||
{ "contractStatusId": 3, "name": "suspended" },
|
||||
{ "contractStatusId": 4, "name": "cancelled" },
|
||||
{ "contractStatusId": 5, "name": "terminated" },
|
||||
],
|
||||
}
|
||||
/actiontypes:
|
||||
get:
|
||||
@ -540,36 +619,16 @@ paths:
|
||||
$ref: "#/components/schemas/ContractStatus"
|
||||
example:
|
||||
{
|
||||
"actionTypes" : [
|
||||
{
|
||||
"contractActionId" : 1,
|
||||
"name" : "create"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 2,
|
||||
"name" : "change"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 3,
|
||||
"name" : "cancel"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 4,
|
||||
"name" : "suspend"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 5,
|
||||
"name" : "terminate"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 6,
|
||||
"name" : "renew"
|
||||
},
|
||||
{
|
||||
"contractActionId" : 7,
|
||||
"name" : "invoice"
|
||||
}
|
||||
]
|
||||
"actionTypes":
|
||||
[
|
||||
{ "contractActionId": 1, "name": "create" },
|
||||
{ "contractActionId": 2, "name": "change" },
|
||||
{ "contractActionId": 3, "name": "cancel" },
|
||||
{ "contractActionId": 4, "name": "suspend" },
|
||||
{ "contractActionId": 5, "name": "terminate" },
|
||||
{ "contractActionId": 6, "name": "renew" },
|
||||
{ "contractActionId": 7, "name": "invoice" },
|
||||
],
|
||||
}
|
||||
components:
|
||||
securitySchemes:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user