Skip to content

location/fulfillment_service_integration/accepted

Overview

PropertyValue
Webhook typelocation/fulfillment_service_integration/accepted
Kafka topiclocation.fulfillment-service-integration.accepted
DirectionPlatform → Your endpoint

Description

Fired when an external fulfillment service accepts the connection request from a HappyColis location. The integration transitions to ACTIVE state, and the location can now send fulfillment orders to this service.

Trigger Conditions

  • The external fulfillment service approves the connection request
  • The FulfillmentServiceIntegration state transitions from PENDING to ACTIVE
  • An access token may be issued at this point

Message Envelope

json
{
  "header": {
    "organizationId": "org_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "messageId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "webhookId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "type": "location/fulfillment_service_integration/accepted",
    "date": "2024-06-10T10:30:00.000Z"
  },
  "body": { ... }
}

Body — Property Table

FulfillmentServiceIntegration Object

FieldTypeNullableDescription
idstring (uuid)NoUnique integration identifier
locationIdstring (uuid)NoThe connected location
fulfillmentServiceIdstring (uuid)NoThe connected fulfillment service
accessTokenstringYesAccess token issued by the fulfillment service (may still be null)
scopesstring[]NoPermission scopes granted
stateenumYesAlways ACTIVE for this event

Full JSON Payload Sample

json
{
  "header": {
    "organizationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "messageId": "t1u2v3w4-x5y6-7890-zabc-123456789012",
    "webhookId": "c3d4e5f6-a7b8-9012-cdef-123456789012",
    "type": "location/fulfillment_service_integration/accepted",
    "date": "2024-06-10T10:30:00.000Z"
  },
  "body": {
    "id": "r9s0t1u2-v3w4-5678-xyza-901234567890",
    "locationId": "j1k2l3m4-n5o6-7890-pqrs-123456789012",
    "fulfillmentServiceId": "s0t1u2v3-w4x5-6789-yzab-012345678901",
    "accessToken": "tok_abc123xyz456",
    "scopes": ["fulfillment:read", "fulfillment:write", "inventory:read"],
    "state": "ACTIVE"
  }
}

Notes

  • state is always ACTIVE in this event payload.
  • The accessToken is the credential used by HappyColis to authenticate requests to the fulfillment service.
  • Once ACTIVE, the location will begin routing eligible delivery orders to the connected fulfillment service.

HappyColis API Documentation