Method
getAssignments POST
Copy POST

Get all positive assignments that match a query.

Arguments:

REQUIRED KEY TYPE DESCRIPTION
Yes deploymentToken str The deployment token used to authenticate access to created deployments. This token is only authorized to predict on deployments in this project, so it can be safely embedded in an application or website.
Yes deploymentId str The unique identifier of a deployment created under the project.
Yes queryData dict Specifies the set of assignments being requested. The value for the key can be: 1. A simple scalar value, which is matched exactly 2. A list of values, which matches any element in the list 3. A dictionary with keys lower_in/lower_ex and upper_in/upper_ex, which matches values in an inclusive/exclusive range
No forcedAssignments dict Set of assignments to force and resolve before returning query results.
No solveTimeLimitSeconds float Maximum time in seconds to spend solving the query.
No includeAllAssignments bool If True, will return all assignments, including assignments with value 0. Default is False.
Note: The arguments for the API methods follow camelCase but for Python SDK underscore_case is followed.

Response:

KEY TYPE DESCRIPTION
success Boolean true if the call succeeded, false if there was an error
OptimizationAssignment

Exceptions:

TYPE WHEN
DataNotFoundError

deploymentId is not found.

Language: