Brett Zufelt Posted November 24, 2020 Share Posted November 24, 2020 I am using the REST Web Services connector in Scribe Connect and am trying to use the POST block to create a new record in my API. The POST request returns a response with the ID of the newly created object. I can't figure out how to be able to then read the response from the POST block and access that ID value to use it to link the newly created record to another record. The only "Operation Results" I have available from my POST block are the standard Result.ErrorDescription, Result.ErrorDetail, Result.ErrorNumber, Result.RecordsMatched, and Result.Success. There is no ID even though I have it defined in the response schema in my swagger doc. Is this expected behavior or am I doing something wrong Here is my Swagger doc: { "swagger": "2.0", "info": { "version": "v3", "title": "Hubspot v3 API", "description": "Hubspot v3 API" }, "host": "api.hubapi.com", "schemes": [ "https" ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "paths": { "/crm/v3/objects/line_items": { "post": { "parameters": [ { "name": "createParams", "in": "body", "required": true, "schema": { "$ref": "#/definitions/LineItemCreateParams" } } ], "responses": { "201": { "schema": { "$ref": "#/definitions/LineItemCreateResponse" } } } } } }, "definitions": { "LineItemCreateParams": { "type": "object", "properties": { "properties": { "$ref": "#/definitions/LineItemProperties" } } }, "LineItemCreateResponse": { "type": "object", "properties": { "id": { "type": "string" } } }, "LineItemProperties": { "type": "object", "properties": { "name": { "type": "string" }, "price": { "type": "number", "format": "double" }, "quantity": { "type": "integer", "format": "int32" } } } } } Link to comment Share on other sites More sharing options...
Nick Roelandt Posted January 12, 2021 Share Posted January 12, 2021 Hi Brettz, I think leveraging the HTTP and Mapper connector extensions will help you achieve your goal. https://help.scribesoft.com/scribe/en/index.htm#sol/conn/conn_ext.htm%3F... With the Mapper connector you are specifiying your request and response JSON example's. You use the HTTP to send the request (post/get etc) build with the Mapper connector and capture the response back from Hubspot in this case thanks Nick Link to comment Share on other sites More sharing options...
Brett Zufelt Posted April 6, 2021 Author Share Posted April 6, 2021 Thanks for the help. Using the HTTP and Mapper connectors did the trick. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now