Performs a device registration to the etherFAX network and returns a security token used for subsequent authentication. Until a device has been created/enabled within the etherFAX network, this function cannot be completed successfully. Devices already registered within the system may not be re-registered until reset within the etherFAX administration portal.

Registering A Device

Before a device can operate within the etherFAX network, it must be created as a customer device and enabled for operation. To begin the registration process, each device must have the current date/time set correctly and create a registration URI following these steps.

In this example, our device serial number is: MT873615726.

Step 1: Create initial MD5 hash using the serial number as input.

Result: 3239f210aefade4a5de84cd018d18b44

Step 2: Create a temporary string using current date/time and initial hash.

"YYYY:MM:hash.DDD"

Where YYYY = year since 1900, MM = current month (0..11), hash (lower case) and DDD is the current day of the year (0..365).

Example: Feb 2, 2017

"0117:01:3239f210aefade4a5de84cd018d18b44.032"

Step 3: Perform final MD5 hash of temporary string.

Result: 414d6d04931da79f6d9925e0c30b85a3

Example:

[GET] https://na.connect.etherfax.net/rest/2.0/api/devices?a=register&id=MT873615726&token=414d6d04931da79f6d9925e0c30b85a3

Response:

{
  "DeviceToken": "54524a6421f1ddaf6781c79f9e176cfc"
}

On success, an HTTP 200/OK response and device security token will be returned. If the device is not enabled or has been previously registered, an HTTP 403/Forbidden is issued.

Once a DeviceToken has been created, the device may authenticate against the etherFAX REST using the same basic authorization semantics. However, the account must be replaced with the literal string of "device/" followed by the device serial number. The password is the DeviceToken returned from the register action. After the device security token is issued, it is the device's responsibility to persist the security token for later use.

Language
Click Try It! to start a request and see the response here!