Errors

Overview

While using the sdk, you may run into an error. Usually this is caused by an invalid parameter in your implementation.


Here is an example of one error you may run into:


{ 
    'httpStatusCode': 401,
    'message': 'Invalid destination provided',
    'info': { unknowns: [ 'moffdd' ] } 
}

To learn more about these and how to solve them, review the error messages below.



Payment Errors:


Spend limit violation


Status code:
409



Error code:
spend_limit_violation



Example:

{ "message": "Request exceeds users global connect spend limit." }



What happened?

The user has reached their Connect limit. Prompt the user to increase their Connect limit from within the HandCash app.



Insufficient funds


Status code:
409



Error code:



Example:

{ "message": "Insufficient funds." }



What happened?

The user account does not hold enough funds to process the transaction. Prompt the user to top up thier account.



Invalid parameters


Status code:
400



Error code:



Example:

{ "message": "Request contains invalid parameters" }



What happened?

You've provided an invalid parameter. Check `info` from the response to find our which one.



Invalid destination


Status code:
409



Error code:



Example:

{ "message": "Invalid destination provided" }



What happened?

The handle, paymail or address you provided is invalid. Ensure the destination you're providing is a valid one.



Non-TSS wallet


Status code:
401



Error code:



Example:

{ "message": "Wallet is not TSS type" }



What happened?

This user has not migrated their wallet to HandCash 2.5.





Other Errors:


Invalid transaction query


Status code:
409



Error code:



Example:

{ "message": "This app didn't create the requested transaction" }



What happened?

You are requesting a transaction made by a different app.



Missing permission


Status code:
401



Error code:



Example:

{ "message": "Permission not established" }



What happened?

You are trying to use a feature that requires a permission not yet granted to you by this user.



Missing authorization


Status code:
401



Error code:



Example:

{ "message": "Missing authorization" }



What happened?

The authorization token is missing or is no longer valid.





HandCash Cloud Errors:

If you recieve an error code with status code 5xx this is an error on the our end.


Here is an example:

{ 
    'httpStatusCode': 503,
    'message': 'External service not available',
    'serviceName': ''
    'info': { } 
}

If you recieve any error with status code 5xx, please get in touch with a HandCash Connect representative to resolve it.


External service unavailable


Status code:
503



Error code:



Example:

{ "message": "External service not available" }



What happened?

We are having difficulties connecting to an external service, and are unable to proccess your request.



Missing authorization


Status code:
500



Error code:



Example:

{ "message": "Internal server error" }



What happened?

HandCash has experienced an internal server error, and is unable to process your request.