Description
Accept an empty pointer or one beginning with slash or hash.
JSON Pointer separates path tokens with slashes and escapes literal slash and tilde inside member names. The empty pointer denotes the document root; an empty token can name an actual empty-string member.
Accept an empty pointer or one beginning with slash or hash.
When to use this tool
Use JSON Pointer URI Fragment Prefix when you need a pointer token, depth, or representation check.
How to use the tool and how it works
- Enter pointer. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read fragmentForm, body. Inspect fragmentForm before interpreting the associated values.
Accept an empty pointer or one beginning with slash or hash. Strip one initial hash for body and mark fragmentForm when it was present.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| pointer | Pointer text in the exact syntax accepted by this tool. | Required. Text; maximum UTF-16 length 8192. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| fragmentForm | Fragment Form | Required. Boolean. |
| body | Body | Required. Text; maximum UTF-16 length 8192. |
{
"input": {
"pointer": "#/a"
},
"output": {
"fragmentForm": true,
"body": "/a"
}
} Limitations and assumptions
- This checks and separates the prefix only; percent decoding, tilde escapes, and pointer resolution are not validated.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
Alternative or Complementary methods
Use a complete pointer parser and resolve against the actual document when existence or array access matters.
References
Similar or alternative tools
- JSON Pointer Terminal Empty Segment
Count slash-separated tokens and mark terminalEmpty for a trailing slash.
- JSON Pointer Relative Up Count Field
Parse a canonical nonnegative up count of at most nine digits followed by hash, a slash path, or nothing.