GET
/
marketing
/
v3
/
forms
/
Obter uma lista de formulários
curl --request GET \
  --url https://api.hubapi.com/marketing/v3/forms/ \
  --header 'Authorization: Bearer <token>'
{
  "results": [
    {
      "id": "b6336282-50ec-465e-894e-e368146fa25f",
      "name": "Contact us",
      "createdAt": "2020-09-22T05:15:12.311Z",
      "updatedAt": "2020-09-22T05:15:35.361Z",
      "archived": false,
      "fieldGroups": [
        {
          "groupType": "default_group",
          "richTextType": "text",
          "fields": [
            {
              "objectTypeId": "0-1",
              "name": "email",
              "label": "Email",
              "required": true,
              "hidden": false,
              "fieldType": "email",
              "validation": {
                "blockedEmailDomains": [],
                "useDefaultBlockList": false
              }
            }
          ]
        },
        {
          "groupType": "default",
          "richTextType": "text",
          "fields": [
            {
              "objectTypeId": "0-1",
              "name": "firstname",
              "label": "First name",
              "required": false,
              "hidden": false,
              "fieldType": "single_line_text"
            }
          ]
        },
        {
          "groupType": "default",
          "richTextType": "text",
          "fields": [
            {
              "objectTypeId": "0-1",
              "name": "lastname",
              "label": "Last name",
              "required": false,
              "hidden": false,
              "fieldType": "single_line_text"
            }
          ]
        },
        {
          "groupType": "default",
          "richTextType": "text",
          "fields": [
            {
              "objectTypeId": "0-1",
              "name": "message",
              "label": "Message",
              "required": false,
              "hidden": false,
              "fieldType": "multi_line_text"
            }
          ]
        }
      ],
      "configuration": {
        "language": "en",
        "cloneable": true,
        "postSubmitAction": {
          "type": "thank_you",
          "value": "Thanks for submitting the form."
        },
        "editable": true,
        "archivable": true,
        "recaptchaEnabled": false,
        "notifyContactOwner": false,
        "notifyRecipients": [
          "2886602"
        ],
        "createNewContactForNewEmail": false,
        "prePopulateKnownValues": true,
        "allowLinkToResetKnownValues": false,
        "lifecycleStages": [
          {
            "objectTypeId": "0-1",
            "value": "subscriber"
          },
          {
            "objectTypeId": "0-2",
            "value": "subscriber"
          }
        ]
      },
      "displayOptions": {
        "renderRawHtml": false,
        "theme": "default_style",
        "submitButtonText": "Submit",
        "style": {
          "fontFamily": "arial, helvetica, sans-serif",
          "backgroundWidth": "100%",
          "labelTextColor": "#33475b",
          "labelTextSize": "13px",
          "helpTextColor": "#7C98B6",
          "helpTextSize": "11px",
          "legalConsentTextColor": "#33475b",
          "legalConsentTextSize": "14px",
          "submitColor": "#ff7a59",
          "submitAlignment": "left",
          "submitFontColor": "#ffffff",
          "submitSize": "12px"
        },
        "cssClass": "hs-form stacked"
      },
      "legalConsentOptions": {
        "type": "none"
      },
      "formType": "hubspot"
    },
    {
      "id": "c7cd13be-3024-4bc8-8582-4a87678b5acc",
      "name": "Pop-up form: Sign up now popup",
      "formType": "flow",
      "createdAt": "2020-09-22T05:19:42.276Z",
      "updatedAt": "2020-09-22T05:20:29.356Z",
      "archived": false
    },
    {
      "id": "ad4497f3-b80a-4369-a7d0-cade0e4c202d",
      "name": "Collected form: .visitorRegistration",
      "formType": "captured",
      "createdAt": "2020-09-22T05:18:40.533Z",
      "updatedAt": "2020-09-22T05:18:40.533Z",
      "archived": false
    }
  ],
  "paging": {
    "next": {
      "after": "Mw%3D%3D",
      "link": "https://api.hubspot.com/marketing/v3/forms?portalId=103268800&limit=3&formTypes=ALL&hs_static_app=api-goggles&hs_static_app_version=1.4854&after=Mw%3D%3D"
    }
  }
}
Produtos suportados
Requer um dos seguintes produtos ou superior.
Marketing HubMarketing HubGrátis
Sales HubSales HubGrátis
Service HubService HubGrátis
Content HubContent HubStarter

Escopos Necessários

Esta API requer um dos seguintes escopos:
  • forms

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Query Parameters

after
string

O token do cursor de paginação do último recurso lido com sucesso será retornado como a propriedade JSON "paging.next.after" de uma resposta paginada que contém mais resultados.

limit
integer

O número máximo de resultados a serem exibidos por página.

archived
boolean

Se apenas os resultados que foram arquivados devem ser retornados.

formTypes
enum<string>[]

Os tipos de formulário a serem incluídos nos resultados.

Response

200
application/json

successful operation

The response is of type object.