-
Notifications
You must be signed in to change notification settings - Fork 11
API codepoint
Manuel Strehl edited this page Jul 14, 2013
·
6 revisions
Template for this request:
http://codepoints.net/api/v1/codepoint/{codepoint}{?property*}
where {codepoint} is a hexadecimal number and {property} is either
no GET parameters at all (for full information) or a list of codepoint
properties to return:
?property=na,age,gc
This request will return a JSON object with three fields:
```json
{
"na": "The Unicode name",
"age": "when the codepoint was added to Unicode",
"gc": "the general category of this codepoint"
}
```
A successful response will contain three to four Link headers:
-
rel=alternatelinks to the description page of the codepoint on the main site. -
rel=uplinks to the API endpoint for the containing Unicode block. -
rel=prevlinks to the previous codepoint, if it exists. -
rel=nextlinks to the next codepoint, if it exists.
- 400 Bad request: If the value for
{codepoint}is not a valid hexadecimal number. - 404 Not found: If the value for
{codepoint}is no recognized codepoint (but a valid hexadecimal number).