Hello
I've created a custom connector in an attempt to simplify interaction with the SurveyMonkey API and when I test the operations from the custom connector's test page I am getting the expected responses but when I try to use them as actions in a flow they return the following:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">
<HTML><HEAD><TITLE>Bad Request</TITLE>
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=us-ascii"></HEAD>
<BODY><h2>Bad Request</h2>
<hr><p>HTTP Error 400. The request is badly formed.</p>
</BODY></HTML>
Swagger definition is:
swagger: '2.0'
info: {version: 1.0.0, title: 'SurveyMonkey API V3 ', description: 'SurveyMonkey API
V3 '}
host: api.surveymonkey.com
basePath: /v3/
schemes: [https]
consumes: []
produces: [application/json]
paths:
/surveys:
get:
summary: Get surveys
description: Return a list of surveys owned or shared with the authenticated
user
operationId: GetSurveys
parameters:
- {name: Content-Type, in: header, required: true, type: string, default: "application/json\r",
description: Content-Type, x-ms-visibility: internal}
- {name: Accept, in: header, required: true, type: string, default: "*/*\r",
description: Accept, x-ms-visibility: internal}
- {name: page, in: query, required: false, type: integer, description: Which
page of resources to return, x-ms-summary: Page}
- {name: title, in: query, required: false, type: string, description: Search
survey list by survey title, x-ms-summary: Title}
- {name: folder_id, in: query, required: false, type: string, description: Specify
the id of a folder to only return surveys in it, x-ms-summary: Folder Id}
responses:
'200':
description: '200'
schema:
type: object
properties:
data:
type: array
items:
type: object
properties:
id: {type: string, description: id}
title: {type: string, description: title}
nickname: {type: string, description: nickname}
href: {type: string, description: href}
description: data
per_page: {type: integer, format: int32, description: per_page}
page: {type: integer, format: int32, description: page}
total: {type: integer, format: int32, description: total}
links:
type: object
properties:
self: {type: string, description: self}
description: links
/surveys/{SURVEY_ID}/responses/bulk:
get:
summary: Get a list of responses by survey id
description: Get a list of responses by survey id, retrieves a list of full
expanded responses, including answers to all questions
operationId: GetAListOfResponsesBySurveyId
parameters:
- {name: SURVEY_ID, in: path, type: string, description: Survey Id, required: true}
- {name: Content-Type, in: header, required: true, type: string, default: "application/json\r",
description: Content-Type, x-ms-visibility: internal}
- {name: Accept, in: header, required: true, type: string, default: "*/*\r",
description: Accept, x-ms-visibility: internal}
- {name: page, in: query, required: false, type: integer, description: Which
page of resources to return, x-ms-summary: Page}
- {name: simple, in: query, required: false, type: string, description: 'When
‘true’, this includes the question and answer text, in addition to IDs',
x-ms-summary: Simple}
responses:
'200':
description: '200'
schema:
type: object
properties:
data:
type: array
items:
type: object
properties:
id: {type: string, description: id}
recipient_id: {type: string, description: recipient_id}
collection_mode: {type: string, description: collection_mode}
response_status: {type: string, description: response_status}
custom_value: {type: string, description: custom_value}
first_name: {type: string, description: first_name}
last_name: {type: string, description: last_name}
email_address: {type: string, description: email_address}
ip_address: {type: string, description: ip_address}
logic_path:
type: object
properties: {}
description: logic_path
metadata:
type: object
properties:
contact:
type: object
properties: {}
description: contact
description: metadata
page_path:
type: array
items: {}
description: page_path
collector_id: {type: string, description: collector_id}
survey_id: {type: string, description: survey_id}
custom_variables:
type: object
properties: {}
description: custom_variables
edit_url: {type: string, description: edit_url}
analyze_url: {type: string, description: analyze_url}
total_time: {type: integer, format: int32, description: total_time}
date_modified: {type: string, description: date_modified}
date_created: {type: string, description: date_created}
href: {type: string, description: href}
pages:
type: array
items:
type: object
properties:
id: {type: string, description: id}
questions:
type: array
items:
type: object
properties:
id: {type: string, description: id}
answers:
type: array
items:
type: object
properties:
choice_id: {type: string, description: choice_id}
simple_text: {type: string, description: simple_text}
tag_data:
type: array
items:
type: object
properties:
hexcolor: {type: string, description: hexcolor}
label: {type: string, description: label}
tag_type: {type: string, description: tag_type}
description: tag_data
text: {type: string, description: text}
description: answers
family: {type: string, description: family}
subtype: {type: string, description: subtype}
heading: {type: string, description: heading}
description: questions
description: pages
description: data
per_page: {type: integer, format: int32, description: per_page}
page: {type: integer, format: int32, description: page}
total: {type: integer, format: int32, description: total}
links:
type: object
properties:
self: {type: string, description: self}
description: links
definitions: {}
parameters: {}
responses: {}
securityDefinitions:
oauth2_auth:
type: oauth2
flow: accessCode
authorizationUrl: https://api.surveymonkey.com/oauth/authorize
tokenUrl: https://api.surveymonkey.com/oauth/token
scopes: {}
security:
- oauth2_auth: []
tags: []
Any ideas on where I've gone wrong?
Thanks!
That's one of the things I intend to use it for, yes.
Are you trying to get the response from SurveyMonkey form using your custom connector?
Thanks