alfred24 2.0 API Reference (1.1-oas3)

Download OpenAPI specification:Download

The alfred24 API allows both logistics and ecommerce partners to utilise the wider alfred24 platform, including smart lockers and pick-up/drop-off (PUDO) points. Access to the alfred24 API will be granted upon provision of a developer account by your alfred24 representative. This account may be used to obtain a bearer token for use with the system. Through using the alfred24 API, you will be able to create and assign shipments to an alfred24 point of your choosing.

HTTP Status Codes

The result of each request is displayed in the HTTP response header, which contains the standard status codes:

HTTP Status Code Description
2xx Success The request was successfully received and proccessed by alfred24
4xx Client Error This indicates there is an error in the payload
5xx Server Error This error occurs when alfred24 is unable to carry out an action

More detailed error messages are listed under each endpoint.

Authorization

All users of the alfred24 API must use a bearer authorization token in the header for each request.

User Authorization

This method is used to authenticate a User based on username and password.
Upon successful call an accessToken will be generated that may be used for other API methods.

Request Body schema: application/json
username
required
string
password
required
string

Responses

Request samples

Content type
application/json
{
  • "username": "Partner",
  • "password": "888888"
}

Response samples

Content type
application/json
{
  • "userId": "4f6296c2-2de1-488a-945e-b27299603961",
  • "username": "Partner",
  • "nickname": null,
  • "mobile": "",
  • "token": "FeimhHNjeqDoS0KBUze8VSraUgTlp1jwHDPwb7jrdOk279AlqwmaMEvf3NLvRIOD",
  • "providerId": null,
  • "roles": [
    ],
  • "authoritySet": [
    ],
  • "merchantName": "Company Example",
  • "merchantId": "cfe4680b09ab11e58bdb0242ac110001",
  • "merchantStatus": "ACTIVE",
  • "accountType": null,
  • "companyType": "OPERATOR",
  • "projectEnvironment": "PROJECT",
  • "languagePreference": null
}

Roles

Get Roles

Authorizations:
bearerAuth
query Parameters
loginType
string
Example: loginType=BACKEND

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Companies

Update Company

Authorizations:
X-USER-TOKEN
Request Body schema: application/json
Array
companyType
string

OPERATOR, LOGISTICS or MERCHANT

merchantName
string

The company name.

productIds
Array of arrays

A list of products available to a company.

merchantStatus
string

ACTIVE || INACTIVE

merchantId
required
string

The UUID of the company.

Responses

Request samples

Content type
application/json
{
  • "companyType": "OPERATOR",
  • "merchantName": "KFC2",
  • "productIds": [ ],
  • "merchantStatus": "ACTIVE",
  • "merchantId": "61adca38-5b88-4f40-a06e-c8142f7aae8b"
}

Response samples

Content type
application/json
[
  • {
    }
]

Users

Create User

Authorizations:
bearerAuth
Request Body schema: application/json
Array
firstName
string

The user's first name.

lastName
string

The user's last name.

username
required
string

The username of the user.

roleIds
required
Array of arrays

The UUID of roles applied to this user.

userStatus
string

ACTIVE || LOCKED

merchantId
required
string

The UUID of the company this user belongs to.

password
required
string

The user's password.

phoneNumber
string

The user's phone number.

loginCode
string

A string which can be converted to a 1D or 2D barcode and scanned at the locker to authenticate.

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
[
  • {
    }
]

Update User

Authorizations:
bearerAuth
Request Body schema: application/json
Array
firstName
string

The user's first name.

lastName
string

The user's last name.

username
string

The username of the user.

roleIds
Array of arrays

The UUID of roles applied to this user.

userStatus
string

ACTIVE || LOCKED

merchantId
string

The UUID of the company this user belongs to.

password
string

The user's password.

userId
required
string

Unique UUID for user generated by system.

phoneNumber
string

The user's phone number.

loginCode
string

A string which can be converted to a 1D or 2D barcode and scanned at the locker to authenticate.

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
[
  • {
    }
]

Get Users

Authorizations:
bearerAuth
query Parameters
username
string
Example: username=UserA
status
string
Example: status=ACTIVE
merchantId
string
Example: merchantId=06616c2e-e450-4885-a666-ed4ce9a40e38

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Delete User

Authorizations:
bearerAuth
Request Body schema: application/json
Array
username
required
string

The user's username

userId
required
string

The user's UUID.

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
[
  • {
    }
]

Shipments

These endpoints are used to manage shipment information within the alfred24 system.

Manifest Shipments

This method is used to manifest Shipments to alfred24 2.0.
Note: Whenever an accessCode is provided, it will be set as the code that the Recipient must use to collect the parcel.
If an accessCode is not set, alfred24 2.0 will generate one for use.

Authorizations:
bearerAuth
Request Body schema: application/json
Array
serviceType
required
string

Available service types include "DELIVERY" and "RETURN".

trackingNumber
required
string

Unique identifer; 8-40 capital letters or numbers only.

additionalTrackingNumber
string

For carriers with multiple shipment identifiers.

referenceNumber
string

Additional identifier for reference.

locationId
string

Unique identifier of alfred24 location.

accessCode
string

6 or 8 number code for customer to access locker. If null system will generate.

recipientPhone
required
string

Recipient phone number

recipientEmail
string

Recipient email address

recipientAddress
string

Recipient mailing address

recipientName
string

Recipient name

recipientId
string

The recipient's identifier used to deliver shipments

note
string

Any miscellaneous remarks

charge
number

COD charges

weight
number

Weight of shipment

overdueTime
string

Define the expiry time on shipment manifest

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{}

Update Shipments

Use this method to update a Shipment with new data.

Authorizations:
bearerAuth
Request Body schema: application/json
Array
trackingNumber
required
string

Unique identifer; 8-40 capital letters or numbers only.

additionalTrackingNumber
string

For carriers with multiple shipment identifiers.

referenceNumber
string

For sender's reference.

locationId
string

Unique identifier of alfred24 location. May only be updated when the shipment status is "CREATED".

accessCode
string

PIN code for customer to access locker. If null system will generate.

recipientPhone
string

Recipient phone number.

recipientEmail
string

Recipient email address.

recipientAddress
string

Recipient mailing address.

recipientName
string

Recipient name

recipientId
string

The recipient's identifier used to deliver shipments.

note
string

Any miscellaneous remarks

charge
integer <int32>

COD charges

weight
number

Weight of shipment

expiryTime
string

Update the expiry time of the shipment

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "SUCCEED": [
    ],
  • "BAD_PARAMETER": [ ],
  • "ALREADY_EXIST": [ ]
}

Get Shipments Information

Use this method to get Shipment information from the backend. It is possible to filter results by a specific status and/or from/to timeframes.

List of Statuses

The statuses returned by alfred24 are as follows:

Status Status Description Notes
CREATED Created Initial status of the shipment
CANCELLED Cancelled Shipment has been cancelled
PICKUP_REQUESTED Pickup requested A courier has been requested to pickup the shipment
DROP_OFF_REQUESTED Delivery Requested The shipment will be dropped off at a warehouse by a merchant
ARRIVED_AT_WAREHOUSE Inbound The shipment has been checked into a warehouse
OUT_FOR_DELIVERY Out for delivery The shipment is out for delivery
COURIER_STORED Courier stored The shipment has arrived at the designated location
CUSTOMER_STORED Customer stored The shipment has been stored at the designated location (for RETURN shipments only)
CUSTOMER_COLLECTED Customer collected The recipient has collected the shipment from the designated location
COURIER_COLLECTED Courier collected A courier has collected the shipment from the designated location (for RETURN shipments only)
OPERATOR_COLLECTED Operator collected The network operator has collected the shipment from the location
RETURNED_TO_COURIER Returned to courier The shipment has expired and a courier has collected it from the location
PICKUP_FAILURE Pickup failure The shipment was not successfully collected from the merchant
STORE_FAILURE Store failure An error has occurred at the locker and the shipment was not successfully registered as stored
SCHEDULED_FOR_DELIVERY Change to delivery The shipment has been rearranged for home delivery
RETURNED_TO_SENDER Returned to merchant The shipment has been returned to the merchant
Authorizations:
bearerAuth
query Parameters
limit
integer <int32>
Example: limit=100

Return limit count in rows.

offset
integer
Example: offset=10

Skip offset count of rows before return.

status
string
Example: status=COURIER_STORED

Status of the Shipment at the given time.

from
string
Example: from=2019-07-01T09:00:00.000Z

YYYY-MM-DDThh-mm-ss.000Z

to
string
Example: to=2019-07-02T13:00:00.000Z

YYYY-MM-DDThh-mm-ss.000Z

serviceType
string
Example: serviceType=DELIVERY

DELIVERY or SEND

trackingNumber
string
Example: trackingNumber=ALFREDPP201907161042TEST

trackingNumber as per shipment identifier

recipentPhone
string
Example: recipentPhone=93793139

Recpient's phone number

locationId
string
Example: locationId=TEST001

Unique identifier of alfred24 location

overdueFlag
boolean
Example: overdueFlag=false

Returns results which have "Expired" status. Valid inputs are 1 = expired, 0 = other status.

userId
string
Example: userId=JS100

Returns shipments which belong to this userId.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Cancel Shipments

Use this method to cancel Shipment(s) already manifested to the system. Shipments may only be cancelled when in the "CREATED" status.

Authorizations:
bearerAuth
Request Body schema: application/json
Array
shipmentId
required
string

Unique string generated upon shipment creation

trackingNumber
required
string

trackingNumber as per shipment identifier

Responses

Request samples

Content type
application/json
[
  • {
    },
  • {
    }
]

Response samples

Content type
application/json
{
  • "SUCCEED": [
    ],
  • "BAD_PARAMETER": [ ],
  • "ALREADY_EXIST": [ ]
}

Update Single Shipment

Use this method to update specific fields of an already manifested Shipment.

Authorizations:
bearerAuth
path Parameters
trackingNumber
required
string

Unique identifier of shipment

Request Body schema: application/json
locationId
string

The locationId as per alfred24 2.0 backend

recipientPhone
string

The recipient's mobile number

accessCode
string

The PIN send to end customer to collect from location

expiryTime
string

Update the expiry time of the shipment

Responses

Request samples

Content type
application/json
{
  • "locationId": "TEST002",
  • "recipientPhone": "536908507",
  • "expiryTime": "1637683200000"
}

Response samples

Content type
application/json
{
  • "serviceType": "DELIVERY",
  • "trackingNumber": "ALFREDPP201907161042TEST",
  • "additionalTrackingNumber": "PP201907161042",
  • "referenceNumber": "ecommerce_reference_number",
  • "recipientPhone": "536908507",
  • "recipientEmail": "recipient@domain.com",
  • "recipientAddress": "MyRecipientAddress",
  • "recipientName": "John Smith",
  • "note": "Thank you for using alfred24",
  • "accessCode": "12345678",
  • "charge": "0",
  • "weight": "2.25 kg",
  • "locationId": "TEST002"
}

Mailroom

These endpoints are to manage users who are displayed at the locker as recipients of unannounced parcels.

Create Mailroom Users

Create Mailroom Users is to generate shipment recipients.

Authorizations:
X-USER-TOKEN
Request Body schema: application/json
firstName
required
string

First name of the recipient. May include alphanumerical characters and symbols.

lastName
required
string

Last name of the recipient. May include alphanumerical characters and symbols.

phoneNumber
string

Maximum character limit is 40 characters. This is required if pushMethod is listed as "PHONE".

email
string

Must contain typical email format; it must contain an "@" and ".". This is required if pushMethod is listed as "EMAIL".

userId
string

This is required if pushMethod is listed as "USER_ID". This field will be sent as a webhook, from which partners can communicate with end customers.

pushMethod
required
string

This field dictates how communications with end customers are made. Available fields include EMAIL, PHONE, USER_ID.

apartmentNumber
string

The apartmentNumber field is used to identify recipients at the locker (if this is the method specified).

locationId
Array of strings

locationId restricts the lockers available to this recipient. Leaving this field empty will enable access to all locations.

Responses

Request samples

Content type
application/json
{
  • "firstName": "J***",
  • "lastName": "D**",
  • "phoneNumber": "+852 9357 1234",
  • "email": null,
  • "userId": null,
  • "pushMethod": "PHONE",
  • "apartmentNumber": 1011,
  • "locationId": [
    ]
}

Response samples

Content type
application/json
{
  • "mailroomId": "41f31edf-d128-416a-a033-f5004db6c017",
  • "firstName": "J***",
  • "lastName": "D**",
  • "apartmentNumber": 1011,
  • "recipientId": [
    ],
  • "locationId": [
    ],
  • "errorMessage": ""
}

Update a Mailroom User

Update a recipient's details.

Authorizations:
X-USER-TOKEN
Request Body schema: application/json
mailroomId
string

The unique identifier of the recipient. It is returned in the create and query methods.

firstName
string

The first name of the recipient.

lastName
string

The last name of the recipient.

phoneNumber
string

The phone number of the recipient. Notifications will be sent to this phone number.

email
string

The email of the recipient. Notifications will be sent to this email address.

userId
string

The assigned user ID of the recipient. This will be returned via webhook upon parcel status update.

pushMethod
string

Push method (EMAIL, PHONE, USER_ID)

apartmentNumber
string

The apartment number of the recipient.

locationId
Array of strings

A list if locations the recipient can receive shipments at.

Responses

Request samples

Content type
application/json
{
  • "mailroomId": "a3cbab66-d6f7-4f35-a919-23c4f473b954",
  • "firstName": "J***",
  • "lastName": "S****",
  • "userId": "JS123",
  • "pushMethod": "USER_ID",
  • "apartmentNumber": "123B",
  • "locationId": ""
}

Response samples

Content type
application/json
{
  • "NOT_PERMISSION": [ ],
  • "SUCCEED": [
    ],
  • "BAD_PARAMETER": [ ],
  • "ALREADY_EXISTS": [ ]
}

Get All Mailroom Users

Get All Mailroom Users is to get all recipients registered in the system.

Authorizations:
X-USER-TOKEN
query Parameters
page
integer <int32>
Example: page=10

Results page.

query
string
Example: query=John

Query string to search for

size
string
Example: size=10

Number of results on a page.

sort
string
Example: sort=lastUpdatedTime

Sort results by the input parameters

Responses

Response samples

Content type
application/json
{
  • "content": {
    },
  • "pagable": [
    ],
  • "last": true,
  • "totalPages": 1,
  • "totalElements": 1,
  • "first": true,
  • "sort": [
    ],
  • "numberOfElements": 1,
  • "size": 10,
  • "number": 10
}

Delete a Mailroom Users

Delete a mailroom user based on mailroom User ID.

Authorizations:
X-USER-TOKEN
query Parameters
mailroomIds
required
string
Example: mailroomIds=632ca172-b0c5-2e14-2ec5-2571cd4fd3e5

mailroomId to delete a recipient

Responses

Response samples

Content type
application/json
{
  • "NOT_PERMISSION": [ ],
  • "SUCCEED": [
    ],
  • "BAD_PARAMETER": [ ]
}

Locations

Methods listed under "Locations" allow users of the alfred24 API to obtain information for all alfred24 locations.

Get All Locations

Get All Locations is used to obtain all locations from the backend system. Pagination may be used via offset or limit.

Authorizations:
bearerAuth
query Parameters
limit
integer <int32>
Example: limit=100

Return limit count in rows.

offset
integer <int32>
Example: offset=25

Skip offset count of rows before return.

locationId
string
Example: locationId=ALF001

Search for locations by their ID.

locationGroup
string
Example: locationGroup=Meriton

Search for locations by the group they are listed under.

postalCode
string
Example: postalCode=2209

Search locatons by postal code. Maximum length 10 characters.

country
string
Example: country=MyCountry

Search locations by country.

city
string
Example: city=MyCity

Search locations by city.

province
string
Example: province=MyRegion

Search locations by province/state/territory.

service
string
Example: service=delivery

Search locations by available services.

locationType
string
Example: locationType=ALFRED_LOCKER, ALFRED_POINT

Search locations by location type.

longitude
string
Example: longitude=151.215168

Search for locations by proximity to these coordinates.

latitude
string
Example: latitude=-33.856873

Search for locations by proximity to these coordinates.

distance
string
Example: distance=1000

Search for locations by proximity to these coordinates within a given radius. Distance is in metres.

showApp
boolean
Example: showApp=true

Search by locations which are available for public viewing.

Responses

Response samples

Content type
application/json
{
  • "limit": 4,
  • "offset": 4,
  • "currentPage": 1,
  • "pageCount": 4,
  • "totalCount": 20,
  • "pagination": [
    ]
}

Get All Locations (Extended)

Get All Locations is used to obtain all locations from the backend system. Pagination may be used via offset or limit. This method is limited to trusted partners only.

Authorizations:
bearerAuth
query Parameters
limit
integer <int32>
Example: limit=100

Return limit count in rows.

offset
integer <int32>
Example: offset=25

Skip offset count of rows before return.

locationId
string
Example: locationId=ALF001

Search for locations by their ID.

locationGroup
string
Example: locationGroup=Meriton

Search for locations by the group they are listed under.

postalCode
string
Example: postalCode=2209

Search locatons by postal code. Maximum length 10 characters.

country
string
Example: country=MyCountry

Search locations by country.

city
string
Example: city=MyCity

Search locations by city.

province
string
Example: province=MyRegion

Search locations by province/state/territory.

service
string
Example: service=delivery

Search locations by available services.

locationType
string
Example: locationType=PUDO, locker

Search locations by location type.

longitude
string
Example: longitude=151.215168

Search for locations by proximity to these coordinates.

latitude
string
Example: latitude=-33.856873

Search for locations by proximity to these coordinates.

distance
string
Example: distance=1000

Search for locations by proximity to these coordinates within a given radius. Distance is in metres.

showApp
boolean
Example: showApp=true

Search by locations which are available for public viewing.

Responses

Response samples

Content type
application/json
{
  • "limit": 4,
  • "offset": 4,
  • "currentPage": 1,
  • "pageCount": 4,
  • "totalCount": 20,
  • "pagination": [
    ]
}

Get All Locations Deprecated

Get All Locations is used to obtain all locations from the backend system. Pagination may be used via offset or limit.

Authorizations:
bearerAuth
query Parameters
limit
integer <int32>
Example: limit=100

Return limit count in rows.

offset
integer <int32>
Example: offset=25

Skip offset count of rows before return.

locationId
string
Example: locationId=ALF001

Search for locations by their ID.

locationGroup
string
Example: locationGroup=Meriton

Search for locations by the group they are listed under.

postalCode
string
Example: postalCode=2209

Search locatons by postal code. Maximum length 10 characters.

country
string
Example: country=MyCountry

Search locations by country.

city
string
Example: city=MyCity

Search locations by city.

province
string
Example: province=MyRegion

Search locations by province/state/territory.

service
string
Example: service=delivery

Search locations by available services.

locationType
string
Example: locationType=PUDO, locker

Search locations by location type.

longitude
string
Example: longitude=151.215168

Search for locations by proximity to these coordinates.

latitude
string
Example: latitude=-33.856873

Search for locations by proximity to these coordinates.

distance
string
Example: distance=1000

Search for locations by proximity to these coordinates within a given radius. Distance is in metres.

showApp
boolean
Example: showApp=true

Search by locations which are available for public viewing.

Responses

Response samples

Content type
application/json
{
  • "limit": 4,
  • "offset": 4,
  • "currentPage": 1,
  • "pageCount": 4,
  • "totalCount": 20,
  • "pagination": [
    ]
}

Webhook

The webhook module enables alfred24 to send callback information to partners based on certain events occurring. The partner must provide alfred24 with a secure webhook notification URL.

Webhook Event Types

The following events trigger a webhook update:
Event Type Description
FOR_MERCHANT_STORE_INBOUND This event is triggered when a shipment is scanned into an affiliated warehouse.
FOR_MERCHANT_STORE_IN_STORE This event is triggered when a shipment has been stored at an alfred24 location by an operator or courier. This event will trigger a notification to a customer if it is enabled.
FOR_MERCHANT_STORE_CUSTOMER_TAKEN This event is triggered when a customer has collected their shipment.
FOR_MERCHANT_STORE_OPERATOR_TAKEN This event is triggered when a shipment has been removed from an alfred24 location to be returned to the locker operator. This event will trigger a notification to the customer if it is enabled.
FOR_MERCHANT_STORE_COURIER_TAKEN This event is triggered when a shipment has been removed from an alfred24 location to be returned to the logistics service provider. This event will trigger a notification to the customer if it is enabled.
FOR_CUSTOMER_STORE_IN_STORE This event is triggered when a shipment has been deposited by a customer. This event is used for SEND shipments.
FOR_CUSTOMER_STORE_COURIER_TAKEN This event is triggered when a shipment has been collected by a courier. This event is used for SEND shipments.
COMPARTMENT_DID_NOT_OPEN This event is triggered when a customer reports a compartment door not opening, meaning the parcel is stuck in the compartment.
COMPARTMENT_DIRTY This event is triggered when a user reports a compartment as dirty at the locker.
PARCEL_OVERSIZE This event is triggered when a shipment has been reported as too large for the locker, requiring extra handling.
LOCKER_FULL This event is triggered when a shipment has been turned away from the locker due to the locker being full.
EMPTY_COMPARTMENT This event is triggered when a customer reports the compartment as being empty
DIRTIED This event is triggered when a compartment is marked as dirty
CANNOT_OPEN This event is triggered when a door has not opened and requires maintenance
LOCKED This event triggers when a door is locked either on the console or at the locker client
AVAILABLE This event is triggered when a compartment status is cleared, returning it to AVAILABLE
LOCKER_DISCONNECTED This event is triggered when the server cannot detect a signal from the locker client.
COM_PORT_DISCONNECTED This event is triggered when a cable has been disconnected from the IPCs COM Port.
SCANNER_BROKEN This event is triggered when a user signals the barcode/QR code scanner is not working at the locker client.
DISK_USAGE_ALERT This event is triggered when the IPCs hard disk is at 90% capacity
LOCKER_75%_FULL This event is triggered when only 25% of the lockers compartments are available.
LOCKER_90%_FULL This event is triggered when the locker only has 10% comaprtments remaining
LOCKER_100%_FULL This event is triggered when the locker has no compartments remaining

In addition to the above trigger events, some triggers may overlap multiple events, such as expired events overlapping both stored and collected events. These are updated through the notifyType field, as per the following table:

Event Type Description
FOR_MERCHANT_STORE_IN_STORE_UPCOMING_EXPIRED This trigger occurs 24 hours before expiration.
FOR_MERCHANT_STORE_IN_STORE_EXPIRED This event triggers when the shipment has expired and is able to be removed from the locker by a courier or operator.

Responses to Webhook

Partners will need to configure their servers to accept webhook information when the events are triggered. \n Acknowledgement of successful receipt of the webhook should be included in the payload as per the example. Repeated attempts to send the webhook information will be made until a successful response is received.

Parcel Status Update Webhook to Partner

Below is a sample webhook response that alfred24 will send on event trigger for PARCEL_STATUS_UPDATE.

Request Body schema: application/json
serviceType
string

Available service types include "DELIVERY and SEND/RETURNS".

trackingNumber
string

Unique identifer; 8-40 capital letters or numbers only.

additionalTrackingNumber
string

For carriers with multiple shipment identifiers.

referenceNumber
string

Additional identifier for reference.

locationId
string

Unique identifier of alfred24 location.

accessCode
string

PIN code for customer to access locker. If null system will generate.

recipientPhone
string

Recipient phone number

recipientEmail
string

Recipient email address

recipientAddress
string

Recipient mailing address

recipientName
string

Recipient name

recipientId
string

The recipient's identifier if anonynimity is to be preserved.

note
string

Any miscellaneous remarks

charge
integer <int32>

COD charges

status
string

Status as it appears to the customer

statusTime
string

Time at which the status was last updated

statusTimestamp
integer

Time at which the status was last updated in timestamp format

overdueTimestamp
integer

Time at which the shipment will be deemed overdue in timestamp format

weight
number

Weight of shipment

length
string

length of shipment

width
string

Width of shipment

height
string

Height of shipment

senderPhone
string

Sender phone number

senderEmail
string

Sender email address

senderAddress
string

Sender mailing address

expressNumber
string

Alternate shipment identifier for those using legacy systems

locationName
string

Name of alfred24 location

compartmentId
string

The unique identifier of a specific compartment

compartmentNumber
string

The compartment number as shown to the customer

event
string

The event which has triggered the webhook update

notifyType
string

Additonal triggers which may overlap multiple events, e.g. expired events may overlap stored and collected events

operator
string

The company to which this shipment belongs to

shipmentType
string

Whether the shipment has been generated at delivery or prior to delivery. announced means it has been generated using web UI or API, unannounced means it has been generated on the locker client.

orderFlag
Array of strings

Any markings applied to the shipment which affects operations

Responses

Request samples

Content type
application/json
{
  • "serviceType": "delivery",
  • "trackingNumber": "CLP0007770000",
  • "additionalTrackingNumber": "CLP0007770000",
  • "referenceNumber": "",
  • "locationId": "ALF001",
  • "accessCode": "77788899",
  • "recipientPhone": "536908434",
  • "recipientEmail": "recipient@domain.com",
  • "recipientAddress": "MyRecipientAddress",
  • "recipientName": "John Smith",
  • "recipientId": "user12345",
  • "note": "Thank you for using alfred24",
  • "charge": "0",
  • "shipmentType": "announced",
  • "status": "FINISHED",
  • "statusTime": "2019-08-01T10:00:00Z",
  • "statusTimestamp": "1573648442070",
  • "overdueTimestamp": "1573648442070",
  • "weight": "2.25 kg",
  • "senderPhone": "536908507",
  • "senderEmail": "sender@domain.com",
  • "senderAddress": "MySenderAddress",
  • "locationName": "alfred24 locker 200",
  • "compartmentId": "57aa117b-c2d4-46c6-a598-d007a629116c",
  • "compartmentNumber": "E11",
  • "event": "FOR_MERCHANT_STORE_CUSTOMER_TAKEN",
  • "notifyType": "FOR_MERCHANT_STORE_IN_STORE_EXPIRED",
  • "operator": "CourierCompany1",
  • "orderFlag": [
    ]
}

Response samples

Content type
text/plain
{
  "status": "success"
}

Parcel Operation Issue Update Webhook to Partner

Below is a sample webhook response that alfred24 will send on event trigger for PARCEL_OPERATION_ISSUE.

Request Body schema: application/json
serviceType
string

Available service types; DELIVERY || SEND/RETURNS.

trackingNumber
string

The tracking number of the shipment.

additionalTrackingNumber
string

For carriers with multiple shipment identifiers.

referenceNumber
string

Additional identifier for reference.

locationId
string

Unique identifier of location.

recipientPhone
string

Recipient phone number

recipientEmail
string

Recipient email address

status
string

The status of the shipment

statusTime
string

The time at which the operation issue occurred

senderPhone
string

The sender's phone number

senderEmail
string

The sender's email address

locationName
string

The name of the location the shipment was to be sent to

compartmentId
string

The unique identifier of the compartment in which the issue occurred

compartmentNumber
string

The local locker number of the compartment in which the issue occurred

event
string

COMPARTMENT_DID_NOT_OPEN || COMPARTMENT_DIRTY || PARCEL_OVERSIZE || LOCKER_FULL || EMPTY_COMPARTMENT || DELIVERY_FAILURE

actor
string

courier || customer

source
string

Where the issue occurred; locker || point

Responses

Request samples

Content type
application/json
{
  • "serviceType": "delivery",
  • "trackingNumber": "CLP0007770000",
  • "additionalTrackingNumber": "CLP0007770000",
  • "referenceNumber": "",
  • "locationId": "ALF001",
  • "recipientPhone": "536908434",
  • "recipientEmail": "recipient@domain.tld",
  • "status": "FINISHED",
  • "statusTime": "2019-08-01T10:00:00Z",
  • "senderPhone": "536908507",
  • "senderEmail": "sender@domain.tld",
  • "locationName": "alfred24 Test 1",
  • "compartmentId": "57aa117b-c2d4-46c6-a598-d007a629116c",
  • "compartmentNumber": "E11",
  • "event": "COMPARTMENT_DID_NOT_OPEN",
  • "actor": "courier",
  • "source": "locker"
}

Response samples

Content type
text/plain
{
  "status": "success"
}

Compartment Issue Update Webhook to Partner

Below is a sample webhook response that alfred24 will send on event trigger for COMPARTMENT_ISSUE.

Request Body schema: application/json
locationId
string

Unique identifier of location

compartmentId
string

The unique identifier of the compartment with an issue

timestamp
string

The timestamp at which the issue is reported (ms)

compartmentNumber
string

The local locker number of the compartment in which the issue occurred

compartmentStatus
string

The status update which triggered the webhook; AVAILABLE || DIRTY || LOCKED || CANNOT OPEN

Responses

Request samples

Content type
application/json
{
  • "locationId": "ALF001",
  • "compartmentId": "57aa117b-c2d4-46c6-a598-d007a629116c",
  • "timestamp": 1629190909585,
  • "compartmentNumber": "E11",
  • "compartmentStatus": "DIRTY"
}

Response samples

Content type
text/plain
{
  "status": "success"
}

Locker Issue Update to Partner

Below is a sample webhook response that alfred24 will send on event trigger for COMPARTMENT_ISSUE.

Request Body schema: application/json
locationId
string

Unique identifier of location

timestamp
string

The timestamp at which the issue occurred (ms)

alert
string

The alert trigger; LOCKER_DISCONNECTED || COM_PORT_DISCONNECTED || LOCKER_DISCONNECTED || LOCKER_75_FULL || LOCKER_90_FULL || LOCKER_100_FULL

alertDetails
string

A description of what the alert means

alertStatus
string

OPEN || CLOSE

Responses

Request samples

Content type
application/json
{
  • "locationId": "ALF001",
  • "timestamp": 1629190909585,
  • "alert": "DISK_USAGE_ALERT",
  • "alertDetails": "Disk utilisation 100%",
  • "alertStatus": "OPEN"
}

Response samples

Content type
text/plain
{
  "status": "success"
}