Manage truckers
Introduction
In Dashdoc, truckers may be created directly from the web interface or using the API. Truckers may log in to the mobile application by entering a 6 character-long invite code. This invite code is one use only, and another one may be generated from the web interface if the trucker needs to log in again (e.g. in case he changes his device).
In any of those ways, if a mobile phone number or an email address in filled at trucker creation, an SMS or an email are sent to the trucker with the invite code (both are sent if both are filled).
If you want to to trucker assignment through the API (for example at transport creation), or if you want to retrieve the trucker that was assigned if it is done through Dashdoc, you will need to have a way to match the list of truckers in your software and in Dashdoc.
There are two ways to achieve that, letting users create truckers using Dashdoc's web interface, or creating truckers using our API
You create truckers using the API (our recommandation)
If you already have a trucker database in your software, this will ensure that both our truckers list are the same.
To do that, you can use the Trucker creation API, and fill in the trucker's info. You will also be able to give us your trucker id in the remote_id
field. The response to the creation request will include our internal id (field pk
), and also the invite_code
that the trucker will have to use to log in to Dashdoc mobile application.
Then, you'll be able to assign transports using either our internal id:
Or using your own id (that you entered in the remote_id
field):
Truckers are created through Dashdoc's web interface
In that case, it means you will need a way to match truckers created in Dashdoc and the ones in your database. The best way to do that is to have the users fill the Dashdoc trucker id in your software. You will then be able to use that id to assign transports to the truckers, using the trucker_id
field in segments:
You will also be able to know which trucker was assigned to transports created/assigned using Dashdoc when you get the transport data (see Retrieve transport data tutorial)
You could also try to automatically match the names of the truckers in Dashdoc and in your database, but there will be some typing errors so that's unfortunately not 100% reliable.
Last updated