Zum Hauptinhalt springen

Return the next TerminationDate for the ContractItem with the given ID

GET/v2/contracts/{contractId}/items/{contractItemId}/next-termination-dates
API-Version
v2
Request-Methode
GET
Operation-ID
deprecated-contract-get-next-termination-date-for-item

Request​

  • contractIdstring (uuid)required

    The uuid of the Contract where the desired ContractItem belongs to.

    Beispiel:"97cecfa0-2c3c-4272-a510-c775fcaade01"
  • contractItemIdstring (uuid)required

    The uuid of the ContractItem whose next TerminationDate is to be displayed.

    Beispiel:"19b3e88e-c656-4440-8b89-efbf881b9c6f"

Responses​

Format
application/json
Beschreibung

Return the next possible TerminationDate for the ContractItem as date.

  • contractItemIdstring (uuid)required
  • nextTerminationDatestring (date-time)required
Content-Type: application/json

{
"contractItemId": "f0f86186-0a5a-45b2-aa33-502777496347",
"nextTerminationDate": "1985-10-26T01:21:00.000Z"
}
{
"properties": {
"contractItemId": {
"format": "uuid",
"type": "string"
},
"nextTerminationDate": {
"format": "date-time",
"type": "string"
}
},
"required": [
"contractItemId",
"nextTerminationDate"
]
}

Nutzungsbeispiele​

$ curl \
--fail \
--location \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
https://api.mittwald.de/v2/contracts/f0f86186-0a5a-45b2-aa33-502777496347/items/f0f86186-0a5a-45b2-aa33-502777496347/next-termination-dates
import { MittwaldAPIV2Client } from "@mittwald/api-client";
import { assertStatus } from "@mittwald/api-client-commons";

const client = MittwaldAPIClient.newWithToken(process.env.MITTWALD_API_TOKEN);
const response = await client.contract.deprecatedContractGetNextTerminationDateForItem({
"contractId": "f0f86186-0a5a-45b2-aa33-502777496347",
"contractItemId": "f0f86186-0a5a-45b2-aa33-502777496347"
});

assertStatus(response, 200);

use \Mittwald\ApiClient\Generated\V2\Clients\Contract\DeprecatedContractGetNextTerminationDateForItem\DeprecatedContractGetNextTerminationDateForItemRequest;

$client = MittwaldAPIClient::newWithToken(getenv('MITTWALD_API_TOKEN'));

$request = (new DeprecatedContractGetNextTerminationDateForItemRequest(
contractId: "f0f86186-0a5a-45b2-aa33-502777496347",
contractItemId: "f0f86186-0a5a-45b2-aa33-502777496347"
));
$response = $client->contract()->deprecatedContractGetNextTerminationDateForItem($request);

var_dump($response->getBody();

Auf dieser Seite