Missions
Terminate Mission Early
Early-terminates an in-progress mission at a given effective date (end_date, YYYY-MM-DD). If the date is today or in the past, the mission is terminated immediately (status terminated). If the date is in the future, the termination is scheduled and finalized automatically on that date. Same business rules as the Folkyn app.
POST
https://api.folkyn.com
/
api
/
v1
/
missions
/
{id}
/
terminate
curl --request POST \
--url https://api.folkyn.com/api/v1/missions/{id}/terminate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"end_date": "2026-06-29",
"reason": "Client ended the engagement early."
}
'{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"has_document": true,
"currency": "EUR",
"rate_amount": 123,
"client_rate_amount": 123,
"start_date": "2023-12-25",
"end_date": "2023-12-25",
"early_termination_date": "2023-12-25",
"terminated_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"external_referent": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"email": "<string>",
"company": "<string>",
"siren": "<string>",
"address": "<string>",
"postal_code": "<string>",
"city": "<string>"
},
"purchase_order": "<string>",
"external_id": "<string>",
"project_code_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_code": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"external_id": "<string>"
},
"project_codes": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"external_id": "<string>"
}
],
"deliverables_catalog": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"quantity": 123,
"amount_excl_vat": 123,
"order_index": 123
}
],
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>"
},
"freelancer": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>",
"email": "<string>",
"referent": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>",
"email": "<string>"
}
},
"team_signer": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>"
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}Authorizations
bearerAuthApiKeyHeader
Use Authorization: Bearer <your_api_key>
Path Parameters
Body
application/json
Early-terminate an in-progress mission. end_date is the effective end date.
Today/past → immediate termination; future → scheduled and finalized on that date.
Response
Success — same object as GET /api/v1/missions/{id}
Show child attributes
Show child attributes
⌘I
curl --request POST \
--url https://api.folkyn.com/api/v1/missions/{id}/terminate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"end_date": "2026-06-29",
"reason": "Client ended the engagement early."
}
'{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"has_document": true,
"currency": "EUR",
"rate_amount": 123,
"client_rate_amount": 123,
"start_date": "2023-12-25",
"end_date": "2023-12-25",
"early_termination_date": "2023-12-25",
"terminated_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"external_referent": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"email": "<string>",
"company": "<string>",
"siren": "<string>",
"address": "<string>",
"postal_code": "<string>",
"city": "<string>"
},
"purchase_order": "<string>",
"external_id": "<string>",
"project_code_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_code": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"external_id": "<string>"
},
"project_codes": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"external_id": "<string>"
}
],
"deliverables_catalog": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"quantity": 123,
"amount_excl_vat": 123,
"order_index": 123
}
],
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>"
},
"freelancer": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>",
"email": "<string>",
"referent": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>",
"email": "<string>"
}
},
"team_signer": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"first_name": "<string>",
"last_name": "<string>"
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}{
"error": {
"code": 401,
"message": "<string>",
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"details": {
"field": "name",
"requiredScope": "tags:write",
"retryAfterSeconds": 1
}
}
}