Expand description
GQL quoting and sanitization helpers.
These mirror the Go reference client’s SanitizeGraphName,
QuoteIdent, and QuoteString so that user-supplied names and string
literals can be inlined into GQL admin statements without opening an
injection vector.
Functions§
- quote_
ident - Validates and returns
namein a form safe to inline into a GQL admin statement that takes an identifier (CREATE USER,ALTER USER,CREATE MIGRATION, etc.). - quote_
string - Returns
swrapped in GQL single quotes, with backslashes and single quotes properly escaped. - sanitize_
graph_ name - Returns
namestripped of any character that is not alphanumeric, underscore, or hyphen, so it can be inlined safely into aUSE GRAPHstatement without opening an injection vector.