# Submit the filing calendar request

Source: https://developer.avalara.com/products/returns/integration-guides/managed-returns/fmv8754955182486/

Guide: Avalara Managed Returns API (U.S. and Canada)

# Submit the filing calendar request

Learn how to submit a filing calendar request using the API. First, construct the payload. Then, view the response.

After you collect all the information:

-   Construct the submission payload including:

    -   Filing frequency

    -   Tax form code

    -   Effective date (for example, the 1st day of the next filing period)

    -   Onboarding question responses

    -   Metadata like country and region

-   Submit the request via the API: The system creates a filing calendar request and the state is set to **NEW**.

**View request**:

```
mutation CreateFilingCalendarRequests {
  createFilingCalendarRequests(
    filingRequestInput: {
      companyId: 999999
      filingRequest: {
        companyId: 999999
        filingRequestStatusId: NEW
        data: {
          answers: [
            {
              filingQuestionCode: "FilingMethod"
              answer: "1"
              filingQuestionId: 2
            }
            {
              filingQuestionId: 24
              answer: "Acme Corporation LLC"
              filingQuestionCode: "LegalEntityName"
            }
            {
              filingQuestionId: 26
              answer: "efile_user_01"
              filingQuestionCode: "EfileUsername"
            }
            {
              filingQuestionId: 27
              answer: "securePassword123"
              filingQuestionCode: "EfilePassword"
            }
            {
              filingQuestionId: 28
              answer: "9876 Elm Street"
              filingQuestionCode: "AddressLine1"
            }
            {
              filingQuestionId: 29
              answer: ""
              filingQuestionCode: "AddressLine2"
            }
            {
              filingQuestionId: 30
              answer: "Springfield"
              filingQuestionCode: "City"
            }
            { filingQuestionId: 31,
              answer: "WI",
              filingQuestionCode: "Region"
            }
            {
              filingQuestionId: 32
              answer: "53703"
              filingQuestionCode: "ZipCode"
            }
            {
              filingQuestionId: 33
              answer: "US"
              filingQuestionCode: "Country"
            }
            {
              filingQuestionId: 34
              answer: "8001234567"
              filingQuestionCode: "Phone"
            }
            {
              filingQuestionId: 36
              answer: "999999999"
              filingQuestionCode: "EIN"
            }
            {
              filingQuestionId: 111
              answer: ""
              filingQuestionCode: "AZOOSloc"
            }
            {
              filingQuestionId: 113
              answer: "654321"
              filingQuestionCode: "AZPin"
            }
            {
              filingQuestionId: 251
              answer: "false"
              filingQuestionCode: "AZRemoteSeller"
            }
          ]
          taxAuthorityName: "ARIZONA"
          taxAuthorityId: null
          region: "AZ"
          country: "US"
          endDate: null
          effDate: "2024-11-01T00:00:00"
          locationCode: null
          registrationId: "123456789"
          filingFrequencyId: MONTHLY
          taxFormCode: "USAZTPT2"
          companyReturnId: null
          isTwoFactorAuthRequired: true
          canValidateEfileCredentials: true
          twoFactorAuthForwardEmail: "abc@test.com"
          twoFactorAlias: "test2FA"
        }
      }
    }
  ) {
    id
    companyId
    filingRequestStatusId
    data {
      autoLockOverrideDay
      companyReturnId
      country
      effDate
      endDate
      filingFrequencyId
      fiscalYearStartMonth
      isClone
      locationCode
      region
      registrationId
      taxAuthorityId
      taxAuthorityName
      taxFormCode
      taxTypeId
      answers {
        answer
        filingQuestionId
        filingQuestionCode
      }
      canValidateEfileCredentials
      twoFactorAuthForwardEmail
      twoFactorAlias
    }
  }
}
```

**View response**:

```
{
  "data": {
    "createFilingCalendarRequests": [
      {
        "id": 999999,
        "companyId": 999999,
        "filingRequestStatusId": "CHANGEREQUEST",
        "data": {
          "autoLockOverrideDay": null,
          "companyReturnId": null,
          "country": "US",
          "effDate": "2024-11-01T00:00:00",
          "endDate": null,
          "filingFrequencyId": "MONTHLY",
          "fiscalYearStartMonth": null,
          "isClone": false,
          "locationCode": null,
          "region": "AZ",
          "registrationId": "123456789",
          "taxAuthorityId": null,
          "taxAuthorityName": "ARIZONA",
          "taxFormCode": "USAZTPT2",
          "taxTypeId": null,
          "answers": [
            {
              "answer": "efile_user_01",
              "filingQuestionId": 26,
              "filingQuestionCode": null
            },
            {
              "answer": "securePassword123",
              "filingQuestionId": 27,
              "filingQuestionCode": null
            }
          ],
          "canValidateEfileCredentials": true,
          "twoFactorAuthForwardEmail": "abc@test.com",
          "twoFactorAlias": "test2FA"
        }
      }
    ]
  }
}
```