RESPONSE CODES

Avior.API returns standard HTTP response.

The response body can contain more information about the error.

CODE

STATUS

DESCRIPTION

200

OK

General success status code.

is the most common code. Used to indicate success.

400

BAD REQUEST

THE REQUEST COULD NOT BE UNDERSTOOD BY THE SERVER DUE TO MALFORMED SYNTAX.

401

UNAUTHORIZED

missing or invalid PASSWORD (EASY MODE), OR

MISSING OR INVALID TIMESTAMP + SIGNATURE (HMAC MODE)

403

FORBIDDEN

the user is not authorized to perform the operation INVALID TIMESTAMP

404

NOT FOUND

RESOURCE NOT FOUND AT GIVEN LOCATION

ACCOUNT DOESN'T EXIST, OR

A WRONG DEVICE PASSWORD HAS BEEN PROVIDED, OR

TOO MANY WRONG PASSWORD

405

METHOD

NOT ALLOWED

the requested HTTP method is not applicable

ALLOWED METHODS :  GET   POST   PUT   DELETE 

413

PAYLOAD TOO LARGE

the REQUEST IS LARGER THAN THE SERVER IS WILING ABLE TO PROCESS

500

INTERNAL

SERVER ERROR

The server encountered an unexpected condition which prevented it from fulfilling the request.

503

SERVICE UNAVAILABLE

THE SERVICE IS CURRENTLY UNAVAILABLE DUE TO SERVER OVERLOAD OR MAINTENANCE, TRY AGAIN IN A FEW MINUTES


To prevent snooping / spoofing, a single error code 404 is returned for:


  • UNKNOWN DEVICE
    REQUESTED ACCOUNT DOESN'T EXIST
    IT MUST BE CREATED FROM DEVICE SIDE.

  • WRONG PASSWORD
    THE PASSWORD DOESN'T MATCH THE ONE STORED INTO THE DEVICE

  • ACCOUNT LOCKED
    SOMEONE TRIED TO ACCESS THE ACCOUNT USING 8 CONSECUTIVE TIMES A WRONG PASSWORD: THE ACCOUNT IS LOCKED AND MUST BE DELETED BY REMOVING THE  APN SETTINGS, THEN PROVIDE THE APN SETTINGS AGAIN TO CREATE A NEW ONE