vraapiclient/catalog.py
def requestResource(self, payload):
        """
		Function that will submit a request based on payload.
		payload = json body (example in request.json)
		Parameters:
			payload = JSON request body.
		"""

        host = self.host
        token = self.token

        url = 'https://{host}/catalog-service/api/consumer/requests'.format(host=host)
        headers = {
            'Content-Type': 'application/json',
            'Accept': 'application/json',
            'Authorization': token
        }
        r = requests.post(url=url,
                          data=json.dumps(payload),
                          headers=headers,
                          verify=False)
        checkResponse(r)

        id = r.headers['location'].split('/')[7]

        return id

		Function that will submit a request based on payload.
		payload = json body (example in request.json)
		Parameters:
			payload = JSON request body.
		
Function that will submit a request based on payload.
payload = json body (example in request.json)
Parameters:
payload = JSON request body.
Function that will submit a request based on payload . payload = json body ( example in request . json ) Parameters : payload = JSON request body .
def requestResource(self, payload):
        host = self.host
        token = self.token
        url = 'https://{host}/catalog-service/api/consumer/requests'.format(host=host)
        headers = {
            'Content-Type': 'application/json',
            'Accept': 'application/json',
            'Authorization': token
        }
        r = requests.post(url=url,
                          data=json.dumps(payload),
                          headers=headers,
                          verify=False)
        checkResponse(r)
        id = r.headers['location'].split('/')[7]
        return id
def requestResource ( self , payload ) : host = self . host token = self . token url = 'https://{host}/catalog-service/api/consumer/requests' . format ( host = host ) headers = { 'Content-Type' : 'application/json' , 'Accept' : 'application/json' , 'Authorization' : token } r = requests . post ( url = url , data = json . dumps ( payload ) , headers = headers , verify = False ) checkResponse ( r ) id = r . headers [ 'location' ] . split ( '/' ) [ 7 ] return id
Function that will submit a request based on payload.
Function that will submit a request based on payload .
"""
		Function that will submit a request based on payload.
		payload = json body (example in request.json)
		Parameters:
			payload = JSON request body.
		"""
self
payload