Retrieving a device from a worker
When a worker leaves your organization, or when they hand back an old device as part of a refresh, IT needs to get the hardware off the worker’s desk and into the right destination. The Deel IT Public API supports three destinations, and the right choice depends on what you want to do with the device next.
This guide covers all three destinations on one page so you can implement the decision logic in your own service and route each device to whichever destination fits your policy.
The GET /rest/it/assets and GET /rest/it/assets/{asset_id} endpoints are stable. Other Deel IT endpoints in this guide are in Beta and may have changes to their request and response shapes. See API versioning for details on endpoint lifecycle states.
Choosing an approach
Sending the device to one of your own warehouses puts the hardware back in your inventory, ready to be redeployed to another worker later. Handing it to Deel for store-and-reuse asks Deel to receive the device into a Deel-managed hub so it can be redeployed on your behalf without a warehouse round-trip. Starting a clearance request retires the device at end of life for resale value or certified data erasure. Which one to prefer, and in what order, depends on the device’s condition, the worker’s location, and your internal policy — this guide describes all three mechanisms and leaves the choice to you.
Prerequisites
A Deel account with Deel IT enabled
Your organization must be onboarded to Deel IT. Clearance is a separate service that must be enabled for your organization before POST /rest/it/assets/{asset_id}/clear will succeed. See Getting Started with Deel IT for the account setup steps, and Deel IT Device Clearance Service for details on the clearance service.
An API token with the required scopes
Three scopes cover all three destinations:
it-assets:readto list the assets currently with a worker.it-service-requests:writeto trigger a collect or clearance request.people:readto resolve a worker or manager to anhris_profile_id.
A destination for the device
Each path needs one of the following:
- A warehouse
idfrom your organization when collecting to your own warehouse. - Nothing extra to collect to a Deel-managed hub — you pass
store_and_reuse_location: "DEEL_HUB"or"LOCAL_HUB". - A manager
hris_profile_idwhen starting a clearance request; this manager is recorded as the requester and receives lifecycle notifications.
Step 1: Find the assets currently with the worker
Every path acts on an asset_id. If your event carries it, skip ahead. If not, list the worker’s active assets to find the ones you want to retrieve. See the List IT assets reference.
Example response:
Each asset carries an id — this is the asset_id you pass to /collect or /clear in the next step. Its grade and product help you decide the right destination for each device.
Step 2: Route each device to a destination
Collect to your own warehouse
Collect to a Deel warehouse for reuse
Clear the asset
Use this path to bring the device back into an organization-owned warehouse. Requires it-service-requests:write scope.
The warehouse_id must reference a warehouse your organization owns; passing a Deel-managed warehouse ID fails. The country field on collection_address overrides the country Deel derives from the asset’s current state — useful when the worker is picking up from an address different from what Deel has on file. See the Create a collection for an IT asset reference.
If you would rather ship without insurance, set shipment_insurance.is_waived to true and omit purchase_details. Use not_before to schedule the pickup for a later date.
Step 3: Track the outcome
POST /rest/it/assets/{asset_id}/collect returns 200 OK. That confirms the request was created, not that the device has moved. The asset then transitions through three location states:
WITH_USER— the request has been created but the courier has not picked the device up yet.WITH_COURIER— the courier has the device in transit.assigned_userbecomesnullonce pickup is registered.AT_WAREHOUSE— the device has arrived at the destination.assigned_warehouseis populated with the warehouse that received it.
Polling for the terminal state
Poll GET /rest/it/assets/{asset_id} to detect the final AT_WAREHOUSE state.
React to a webhook instead
If you would rather not poll, subscribe to the it-asset.location-updated event to receive a callback whenever an asset’s location changes. Deel delivers a webhook when the asset moves to WITH_COURIER and again when it arrives at AT_WAREHOUSE. Filter incoming events on the asset ID you started the collect with, and check the location field to detect the terminal state.
See Webhooks for how to register an endpoint and verify signatures, and Discovering available events for the full event catalogue.
Clearance requests do not currently emit webhook events — poll GET /rest/it/clearance-requests/{clearance_request_id} to track the clearance status through to COMPLETED.
Example automated flow
If you are building this as an automated service — for example, an offboarding workflow that runs whenever a worker leaves — here is one example of how the steps can be sequenced. This is illustrative; the API does not prescribe any particular order, and you can adapt these steps to fit your own policy.
List the worker's active devices
Call GET /rest/it/assets?hris_profile_id={worker_id}&location=WITH_USER&status=ACTIVE to get every device currently with them.
Choose a destination for each device
Apply your own policy — for example, laptops in good condition go to a Deel hub for reuse, laptops at end of life go to clearance, and everything else goes back to your own warehouse.
Trigger the right request per device
Call POST /rest/it/assets/{asset_id}/collect for a collect, or POST /rest/it/assets/{asset_id}/clear for a clearance.
Confirm the outcome
For collect, watch for location=AT_WAREHOUSE on the resulting asset — either by polling GET /rest/it/assets/{asset_id} or by subscribing to it-asset.location-updated. For clear, poll the clearance request status until it reaches COMPLETED. Then close out the task in your internal system.