PC2Paper Logo

API Error Messages

Below is a list of error messages provided by our API's

How error message are formated

Error message will follow a certain format dependent on the API endpoint you are using. So for example if you are using our JSON RESTFull API error messages will be returned in the following format:

{ "d": { "__type": "LetterForPostingResult:#PC2Paper.Entity.Public.Letters", "CostOfLetter": 0, "ErrorMessages": [ "ER11:The Postage option 31 does not support the envelope type 1 with the amount of pages in your document. You can only use these envelope types for this Postage option:10, 11, 18, " ], "FundsLeftInYourAccount": 0, "LetterId": null, "Status": "Error" } }

As you can see the ErrorMessages object will contain an array of error messages (if there are any). Error messages will usually be in the following format

ER[code]:A human readable format of the error message

However some error messages may appear without an error code. 

ER5: Login Failed
username and password did not match

Returned when your login name and password were incorrect.

ER6: Submitted a field that should not have been empty

You will receive this error when you have submitted a field that is blank and
should have contained a value. The error code should return the name of the
field.

You will receive this error when you have submitted a field that is blank and should have contained a value. The error code should return the name of the field.

ER7: Field must be integer

You will receive this error when the field you submitted should have contained and integer value and did not. The error code should return the name of the field.

ER8: Field is not a recognised country id

You will receive this error code when the field should have contained a country id 

ER11: Incompatible Postage configuration

You have attempted to use postage options together that are not compatible. For example you may have tried to use an envelope type that was only available in a certain postage zone. 

There was an error opening the PDF [filename] is it a proper PDF?

The site was not able to open the PDF. Make sure its not a corrupt file

There was an error saving the PDF

The site was unable to save your PDF. Make sure its not a corrupt file

The PDF [filename] is print protected

We cannot print the PDF because it is print protected

The PDF [filename] must be either A4 or Letter size

We can only accept Letter size or A4 sized PDF's

Insufficient funds left in your account

You do not have enough funds in your account to send letter. You will need to top-up your account.