{
  "swagger": "2.0",
  "info": {
    "version": "1.1",
    "title": "Cognito Forms",
    "description": "Cognito Forms lets you easily build powerful online forms, such as surveys, order forms, registration forms and more. For free.",
    "x-ms-api-annotation": {
      "status": "Preview"
    },
    "contact": {
      "name": "Cognito Forms Support",
      "email": "support@cognitoforms.com",
      "url": "https://www.cognitoforms.com/support"
    }
  },
  "host": "cognitoforms.com",
  "basePath": "/",
  "schemes": [
    "https"
  ],
  "consumes": [],
  "produces": [],
  "paths": {
    "/api/forms": {
      "get": {
        "tags": [
          "Forms"
        ],
        "summary": "Get Forms",
        "description": "Retrieves a list of forms in your organization that are accessible by the specified API key. Archived forms are not included in the response.",
        "operationId": "GetForms",
        "consumes": [],
        "produces": [
          "application/json",
          "text/json"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "array",
              "items": {
                "description": "A form reference that includes the name and ID of the form",
                "type": "object",
                "properties": {
                  "Id": {
                    "description": "The unique ID of the form",
                    "type": "string"
                  },
                  "Name": {
                    "description": "The name of the form",
                    "type": "string"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "429": {
            "description": "Too Many Requests",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-visibility": "internal"
      }
    },
    "/api/forms/{form}/schema": {
      "get": {
        "tags": [
          "Forms"
        ],
        "summary": "Get form schema",
        "description": "Gets the Swagger schema for a specific form.",
        "operationId": "GetFormSchema",
        "consumes": [],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form.",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-test-value": "1",
            "type": "string"
          },
          {
            "name": "input",
            "in": "query",
            "description": "Input",
            "required": false,
            "x-ms-summary": "Input",
            "type": "boolean"
          },
          {
            "name": "includeLinks",
            "in": "query",
            "description": "Include Links",
            "required": false,
            "x-ms-summary": "Include Links",
            "type": "boolean"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-visibility": "internal"
      }
    },
    "/api/forms/{form}/entries": {
      "post": {
        "tags": [
          "Entries"
        ],
        "summary": "Create entry",
        "description": "Creates a new entry.",
        "operationId": "CreateEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "entry",
            "in": "body",
            "description": "The entry to create for the form",
            "required": true,
            "schema": {
              "type": "object",
              "x-ms-dynamic-schema": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameter": "form"
                  },
                  "input": true
                },
                "value-path": "properties"
              },
              "x-ms-dynamic-properties": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameterReference": "form"
                  },
                  "input": {
                    "value": true
                  }
                }
              }
            },
            "x-ms-summary": "Entry"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object",
              "x-ms-dynamic-schema": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameter": "form"
                  },
                  "input": false
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Creates a new entry.",
        "x-ms-visibility": "important"
      }
    },
    "/api/forms/{form}/entries/{entryId}": {
      "get": {
        "tags": [
          "Entries"
        ],
        "summary": "Get entry",
        "description": "Gets an entry.",
        "operationId": "GetEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string",
            "x-ms-visibility": "important"
          },
          {
            "name": "entryId",
            "in": "path",
            "description": "The entry id",
            "required": true,
            "x-ms-summary": "Entry Id",
            "type": "string",
            "x-ms-visibility": "important"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object",
              "x-ms-dynamic-schema": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameter": "form"
                  },
                  "input": false
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Gets an entry.",
        "x-ms-visibility": "important"
      },
      "delete": {
        "tags": [
          "Entries"
        ],
        "summary": "Delete entry",
        "description": "Delete an entry.",
        "operationId": "DeleteEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string",
            "x-ms-visibility": "important"
          },
          {
            "name": "entryId",
            "in": "path",
            "description": "The entry id",
            "required": true,
            "x-ms-summary": "Entry Id",
            "type": "string",
            "x-ms-visibility": "important"
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Deletes an entry.",
        "x-ms-visibility": "important"
      },
      "patch": {
        "tags": [
          "Entries"
        ],
        "summary": "Update entry",
        "description": "Updates an entry.",
        "operationId": "EditEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string",
            "x-ms-visibility": "important"
          },
          {
            "name": "entryId",
            "in": "path",
            "description": "The entry id",
            "required": true,
            "x-ms-summary": "Entry Id",
            "type": "string",
            "x-ms-visibility": "important"
          },
          {
            "name": "entry",
            "in": "body",
            "description": "The updated entry data",
            "required": true,
            "schema": {
              "type": "object",
              "x-ms-dynamic-schema": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameter": "form"
                  },
                  "input": true
                },
                "value-path": "properties"
              },
              "x-ms-dynamic-properties": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameterReference": "form"
                  },
                  "input": {
                    "value": true
                  }
                }
              }
            },
            "x-ms-summary": "Entry"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object",
              "x-ms-dynamic-schema": {
                "operationId": "GetFormSchema",
                "parameters": {
                  "form": {
                    "parameter": "form"
                  },
                  "input": false
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Updates an entry.",
        "x-ms-visibility": "important"
      }
    },
    "/api/forms/{form}/entries/{entry}/documents/{templateNumber}": {
      "get": {
        "tags": [
          "Entries"
        ],
        "summary": "Get Document",
        "description": "Gets a document",
        "operationId": "GetDocument",
        "produces": [
          "application/pdf",
          "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "entry",
            "in": "path",
            "description": "The entry id",
            "required": true,
            "x-ms-summary": "Entry Id",
            "type": "string"
          },
          {
            "name": "templateNumber",
            "in": "path",
            "description": "The template number",
            "required": true,
            "x-ms-summary": "Template Number",
            "type": "integer"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "$ref": "#/definitions/FileDataRef"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Gets a document",
        "x-ms-visibility": "important"
      }
    },
    "/api/forms/{form}/public-link-availability": {
      "post": {
        "tags": [
          "Forms"
        ],
        "summary": "Set form availability",
        "description": "Sets the availability of a form.",
        "operationId": "SetFormAvailability",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "start",
            "in": "body",
            "description": "Availability",
            "required": false,
            "schema": {
              "type": "object",
              "properties": {
                "start": {
                  "description": "Availability start date",
                  "type": "string",
                  "format": "date-time",
                  "x-ms-summary": "Availability Start"
                },
                "end": {
                  "description": "Availability end date",
                  "type": "string",
                  "format": "date-time",
                  "x-ms-summary": "Availability End"
                },
                "message": {
                  "description": "Not Available Message",
                  "type": "string",
                  "x-ms-summary": "Not Available Message"
                }
              }
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "$ref": "#/definitions/FormAvailability"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "Sets form availability.",
        "x-ms-visibility": "important"
      }
    },
    "/api/forms/{form}/import-entries": {
      "post": {
        "tags": [
          "Entries"
        ],
        "summary": "Import Entries",
        "description": "Creates, updates, or deletes entries using provided file content.",
        "operationId": "ImportEntries",
        "consumes": [
          "multipart/form-data"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the form",
            "required": true,
            "type": "string",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "x-ms-summary": "Form"
          },
          {
            "name": "File",
            "in": "formData",
            "description": "The file (.xlsx or .csv) containing the entries to import.",
            "required": true,
            "type": "file",
            "x-ms-media-kind": "file",
            "x-ms-summary": "Import File"
          },
          {
            "name": "ImportMode",
            "in": "formData",
            "description": "The mode for the import",
            "required": true,
            "type": "string",
            "enum": [
              "CreateNew",
              "UpdateExisting",
              "SyncEntries"
            ],
            "x-ms-summary": "Import Mode"
          },
          {
            "name": "Email",
            "in": "formData",
            "description": "The email address to receive import notifications",
            "type": "string",
            "format": "email",
            "x-ms-summary": "Notification Email"
          },
          {
            "name": "MatchEntriesUsing",
            "in": "formData",
            "description": "An entry ID substitute",
            "type": "string",
            "x-ms-summary": "Match Field"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object",
              "properties": {
                "Id": {
                  "type": "string",
                  "description": "The ID of the import"
                },
                "Status": {
                  "type": "string",
                  "description": "The status of the import"
                },
                "ErrorMessage": {
                  "type": "string",
                  "description": "A message describing why the import failed"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "429": {
            "description": "Too Many Requests",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "x-ms-visibility": "important"
      }
    },
    "/api/forms/{form}/import-status/{importId}": {
      "get": {
        "tags": [
          "Entries"
        ],
        "summary": "Get Import Status",
        "description": "Gets the current status of an import and returns the number of successful and unsuccessful entries.",
        "operationId": "GetImportStatus",
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "description": "The name of the Form",
            "required": true,
            "type": "string",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "x-ms-summary": "Form"
          },
          {
            "name": "importId",
            "in": "path",
            "description": "The Import ID",
            "required": true,
            "type": "string",
            "x-ms-summary": "Import ID"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "description": "The status of an import",
              "type": "object",
              "properties": {
                "Id": {
                  "description": "The ID of the import",
                  "type": "string"
                },
                "Status": {
                  "description": "The status of the import",
                  "type": "string"
                },
                "ErrorMessage": {
                  "description": "A message describing why the import failed",
                  "type": "string"
                },
                "SuccessfulEntries": {
                  "description": "The number of entries successfully imported",
                  "type": "integer"
                },
                "UnsuccessfulEntries": {
                  "description": "The number of entries that failed to import",
                  "type": "integer"
                },
                "TotalEntries": {
                  "description": "The total number of entries in the import",
                  "type": "integer"
                },
                "ImportLink": {
                  "description": "The link to the entries page to download the annotated file",
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "429": {
            "description": "Too Many Requests",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          }
        },
        "x-ms-visibility": "important"
      }
    },
    "/integration/oauth/subscribenewentry": {
      "x-ms-notification-content": {
        "description": "Hook response from Cognito",
        "schema": {
          "type": "object",
          "x-ms-dynamic-schema": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameter": "publisher"
              }
            },
            "value-path": "properties"
          },
          "x-ms-dynamic-properties": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameterReference": "publisher"
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Cognito Forms"
        ],
        "summary": "When a new entry is created",
        "description": "Triggers when someone creates a new entry.",
        "operationId": "NewEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "module",
            "in": "query",
            "x-ms-visibility": "internal",
            "type": "string",
            "default": "forms",
            "required": true
          },
          {
            "name": "publisher",
            "in": "query",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "endpoint",
            "in": "body",
            "required": true,
            "schema": {
              "type": "object",
              "required": [
                "notificationUrl"
              ],
              "properties": {
                "notificationUrl": {
                  "description": "The URL to call back to.",
                  "type": "string",
                  "x-ms-summary": "Notification URL",
                  "x-ms-notification-url": true,
                  "x-ms-visibility": "internal"
                }
              }
            },
            "x-ms-visibility": "internal"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "201": {
            "description": "Created"
          },
          "400": {
            "description": "Bad Request"
          },
          "401": {
            "description": "Unauthorized"
          },
          "403": {
            "description": "Forbidden"
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred"
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "When a new entry is created",
        "x-ms-trigger": "single",
        "x-ms-visibility": "important"
      }
    },
    "/integration/oauth/subscribeupdateentry": {
      "x-ms-notification-content": {
        "description": "Hook response from Cognito",
        "schema": {
          "type": "object",
          "x-ms-dynamic-schema": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameter": "publisher"
              }
            },
            "value-path": "properties"
          },
          "x-ms-dynamic-properties": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameterReference": "publisher"
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Cognito Forms"
        ],
        "summary": "When an entry is updated",
        "description": "Triggers when someone updates an entry.",
        "operationId": "UpdateEntry",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "module",
            "in": "query",
            "x-ms-visibility": "internal",
            "type": "string",
            "default": "forms",
            "required": true
          },
          {
            "name": "publisher",
            "in": "query",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "endpoint",
            "in": "body",
            "required": true,
            "schema": {
              "type": "object",
              "required": [
                "notificationUrl"
              ],
              "properties": {
                "notificationUrl": {
                  "description": "The URL to call back to.",
                  "type": "string",
                  "x-ms-summary": "Notification URL",
                  "x-ms-notification-url": true,
                  "x-ms-visibility": "internal"
                }
              }
            },
            "x-ms-visibility": "internal"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "201": {
            "description": "Created"
          },
          "400": {
            "description": "Bad Request"
          },
          "401": {
            "description": "Unauthorized"
          },
          "403": {
            "description": "Forbidden"
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred"
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "When an entry is updated",
        "x-ms-trigger": "single",
        "x-ms-visibility": "important"
      }
    },
    "/integration/oauth/subscribeentrydeleted": {
      "x-ms-notification-content": {
        "description": "Hook response from Cognito",
        "schema": {
          "type": "object",
          "x-ms-dynamic-schema": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameter": "publisher"
              },
              "includeLinks": false
            },
            "value-path": "properties"
          },
          "x-ms-dynamic-properties": {
            "operationId": "GetFormSchema",
            "parameters": {
              "form": {
                "parameterReference": "publisher"
              },
              "includeLinks": {
                "value": false
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Cognito Forms"
        ],
        "summary": "When an entry is deleted",
        "description": "Triggers when someone deletes an entry.",
        "operationId": "EntryDeleted",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "module",
            "in": "query",
            "x-ms-visibility": "internal",
            "type": "string",
            "default": "forms",
            "required": true
          },
          {
            "name": "publisher",
            "in": "query",
            "description": "The name of the form",
            "required": true,
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            },
            "type": "string"
          },
          {
            "name": "endpoint",
            "in": "body",
            "required": true,
            "schema": {
              "type": "object",
              "required": [
                "notificationUrl"
              ],
              "properties": {
                "notificationUrl": {
                  "description": "The URL to call back to.",
                  "type": "string",
                  "x-ms-summary": "Notification URL",
                  "x-ms-notification-url": true,
                  "x-ms-visibility": "internal"
                }
              }
            },
            "x-ms-visibility": "internal"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "201": {
            "description": "Created"
          },
          "400": {
            "description": "Bad Request"
          },
          "401": {
            "description": "Unauthorized"
          },
          "403": {
            "description": "Forbidden"
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred"
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-trigger-hint": "When an entry is deleted",
        "x-ms-trigger": "single",
        "x-ms-visibility": "important"
      }
    },
    "/integration/oauth/unsubscribe": {
      "delete": {
        "tags": [
          "Cognito Forms"
        ],
        "summary": "Unsubscribe Webhook",
        "description": "Unsubscribes a webhook.",
        "operationId": "UnsubscribeWebhook",
        "consumes": [
          "application/json",
          "text/json"
        ],
        "produces": [
          "application/json",
          "text/json"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "query",
            "description": "The unique subscription id.",
            "x-ms-summary": "Subscription",
            "type": "string"
          },
          {
            "name": "module",
            "in": "query",
            "description": "The module the subscription is associated with.",
            "x-ms-summary": "Module",
            "type": "string",
            "default": "forms"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "201": {
            "description": "Created"
          },
          "400": {
            "description": "Bad Request"
          },
          "401": {
            "description": "Unauthorized"
          },
          "403": {
            "description": "Forbidden"
          },
          "404": {
            "description": "Not Found"
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred"
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-no-generic-test": true,
        "x-ms-visibility": "internal"
      }
    },
    "/api/files/{id}": {
      "get": {
        "tags": [
          "Entries"
        ],
        "summary": "Get File",
        "description": "Gets a file by id.",
        "operationId": "GetFile",
        "consumes": [],
        "produces": [
          "application/octet-stream"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The unique identifier of the file",
            "required": true,
            "x-ms-summary": "File Id",
            "x-ms-test-value": "1",
            "type": "string"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "$ref": "#/definitions/FileDataRef"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "deprecated": false,
        "x-ms-visibility": "important"
      }
    },
    "/api/odata/Forms({form})/Views({viewId})/Entries": {
      "get": {
        "tags": [
          "Entries"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "schema": {
              "type": "object"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "403": {
            "description": "Forbidden",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "500": {
            "description": "Internal Server Error. Unknown error occurred",
            "schema": {
              "$ref": "#/definitions/Error"
            }
          },
          "default": {
            "description": "Operation Failed"
          }
        },
        "operationId": "GetEntryViewEntries",
        "x-ms-visibility": "important",
        "parameters": [
          {
            "name": "form",
            "in": "path",
            "required": true,
            "type": "string",
            "description": "The name of the Form",
            "x-ms-summary": "Form",
            "x-ms-dynamic-values": {
              "operationId": "GetForms",
              "value-path": "Id",
              "value-title": "Name"
            }
          },
          {
            "name": "viewId",
            "in": "path",
            "required": true,
            "type": "string",
            "description": "The ID of the view",
            "x-ms-summary": "View ID"
          },
          {
            "name": "$count",
            "in": "query",
            "required": false,
            "type": "string",
            "description": "Include total count of entries",
            "x-ms-summary": "Include Count"
          },
          {
            "name": "$select",
            "in": "query",
            "description": "Returns list of entry IDs in a View when $select=Id is specified",
            "required": false,
            "type": "string",
            "x-ms-summary": "Select Ids"
          }
        ],
        "description": "Get all of the entries for a specified view",
        "summary": "Get Form Entries"
      }
    }
  },
  "definitions": {
    "FileDataRef": {
      "description": "A file reference that includes file data and metadata",
      "type": "object",
      "properties": {
        "Id": {
          "description": "The unique id of the file.",
          "type": "string",
          "x-ms-summary": "File Id",
          "x-ms-visibility": "important"
        },
        "Name": {
          "description": "The name of the file",
          "type": "string",
          "x-ms-summary": "File Name",
          "x-ms-visibility": "important"
        },
        "ContentType": {
          "description": "The content type of the file.",
          "type": "string",
          "x-ms-summary": "File Content Type",
          "x-ms-visibility": "important"
        },
        "Size": {
          "description": "The size of the file.",
          "type": "integer",
          "x-ms-summary": "File Size",
          "x-ms-visibility": "important"
        },
        "File": {
          "description": "The URL of the file.",
          "type": "string",
          "x-ms-summary": "File URL",
          "x-ms-visibility": "important"
        },
        "Content": {
          "description": "The file content",
          "type": "string",
          "format": "byte",
          "x-ms-summary": "File Content",
          "x-ms-visibility": "important"
        }
      }
    },
    "FormAvailability": {
      "description": "Form availability information such as start/end availability and not available message.",
      "type": "object",
      "properties": {
        "availabilityStart": {
          "description": "Form availability start",
          "type": "string",
          "format": "date-time",
          "x-ms-summary": "Form availability start",
          "x-ms-visibility": "important"
        },
        "availabilityEnd": {
          "description": "Form availability end",
          "type": "string",
          "format": "date-time",
          "x-ms-summary": "Form availability end",
          "x-ms-visibility": "important"
        },
        "notAvailableMessage": {
          "description": "Not available message",
          "type": "string",
          "x-ms-summary": "Not available message",
          "x-ms-visibility": "important"
        }
      }
    },
    "Error": {
      "description": "An error",
      "type": "object",
      "properties": {
        "Message": {
          "description": "A message describing the error",
          "type": "string",
          "x-ms-summary": "Error Message"
        },
        "Type": {
          "description": "The type of the error",
          "type": "string",
          "x-ms-summary": "Error Type"
        },
        "SupportCode": {
          "description": "A support code identifying the specific error",
          "type": "string",
          "x-ms-summary": "Error Support Code"
        },
        "Data": {
          "description": "Data related to the error",
          "type": "object",
          "x-ms-summary": "Error Data"
        }
      }
    }
  },
  "parameters": {},
  "responses": {},
  "securityDefinitions": {
    "oauth2-auth": {
      "type": "oauth2",
      "flow": "accessCode",
      "authorizationUrl": "https://cognitoforms.com/api-connection",
      "tokenUrl": "https://cognitoforms.com/admin/oauthtoken",
      "scopes": {
        "admin": "admin"
      }
    }
  },
  "security": [
    {
      "oauth2-auth": [
        "admin"
      ]
    }
  ],
  "tags": [],
  "x-ms-connector-metadata": [
    {
      "propertyName": "Website",
      "propertyValue": "https://www.cognitoforms.com"
    },
    {
      "propertyName": "Privacy Policy",
      "propertyValue": "https://www.cognitoforms.com/legal/privacy"
    },
    {
      "propertyName": "Categories",
      "propertyValue": "Productivity;Collaboration"
    }
  ],
  "x-ms-capabilities": {
    "testConnection": {
      "operationId": "GetForms"
    }
  }
}