ErrorCode

1
2
3
4
5
{
    "Name": "RESTar.Admin.ErrorCode",
    "Kind": "EntityResource",
    "Methods": ["GET", "REPORT", "HEAD"]
}

The error codes used by RESTar have their own resource, which is useful for administrators wanting to check some error code that appears in Error entities.

Example

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
GET https://my-server.com/rest/errorcode/code<5
Headers: "Authorization: apikey mykey"
Response body:
[
    {
        "Name": "NoError",
        "Code": -1
    },
    {
        "Name": "Unknown",
        "Code": 0
    },
    {
        "Name": "InvalidUriSyntax",
        "Code": 1
    },
    {
        "Name": "InvalidMetaConditionValueType",
        "Code": 2
    },
    {
        "Name": "InvalidMetaConditionOperator",
        "Code": 3
    },
    {
        "Name": "InvalidMetaConditionSyntax",
        "Code": 4
    }
]