ParamsBuilder

class pysnow.params_builder.ParamsBuilder[source]

Provides an interface for setting / getting common ServiceNow sysparms.

static stringify_query(query)[source]

Stringifies the query (dict or QueryBuilder) into a ServiceNow-compatible format

Returns:
  • ServiceNow-compatible string-type query
add_custom(params)[source]

Adds new custom parameter after making sure it’s of type dict.

Parameters:params – Dictionary containing one or more parameters
custom_params

Returns a dictionary of added custom parameters

display_value

Maps to sysparm_display_value

query

Maps to sysparm_query

limit

Maps to sysparm_limit

offset

Maps to sysparm_offset

fields

Maps to sysparm_fields

Maps to sysparm_exclude_reference_link

suppress_pagination_header

Maps to sysparm_suppress_pagination_header

as_dict()[source]

Constructs query params compatible with requests.Request

Returns:
  • Dictionary containing query parameters