post¶
-
lsst.verify.squash.post(api_url, api_endpoint, json_doc=None, api_user=None, api_password=None, timeout=None, version=None)[source]¶ POST a JSON document to SQUASH.
Parameters: api_url :
strRoot URL of the SQUASH API. For example,
'https://squash.lsst.codes/api'.api_endpoint :
strName of the API endpoint to post to.
json_doc :
dictA JSON-serializable object.
api_user :
strAPI username.
api_password :
strAPI password.
timeout :
float, optionalRequest timeout. The value of
get_default_timeoutis used by default.version :
str, optionalAPI version. The value of
get_default_api_versionis used by default.Returns: response :
requests.ResponseResponse object. Obtain JSON content with
response.json().Raises: requests.exceptions.RequestException
Raised if the HTTP request fails.