> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # CountSubmissionsByIntakeFormIds # Package: intakeForms # Namespace: IntakeFormSubmissionsService # Method link: https://dev.wix.com/docs/api-reference/crm/forms/other-services/intake-forms/intake-form-submissions/count-submissions-by-intake-form-ids.md ## Permission Scopes: Read Intake Form: SCOPE.INTAKE-FORM.READ ## Introduction Counts intake form submissions by form IDs. Returns the total number of submissions per intake form. If you include a deleted intake form ID in the request, that form is omitted from the response. Use this method for analytics, reporting, or checking if a form has submissions before deleting it. --- ## REST API ### Schema ``` Method: countSubmissionsByIntakeFormIds Description: Counts intake form submissions by form GUIDs. Returns the total number of submissions per intake form. If you include a deleted intake form GUID in the request, that form is omitted from the response. Use this method for analytics, reporting, or checking if a form has submissions before deleting it. URL: https://www.wixapis.com/intake-forms/v1/intake-form-submissions/count Method: POST # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: intakeFormIds Method parameters: param name: intakeFormIds | type: array | description: List of intake form GUIDs to count submissions for. | required: true Return type: CountSubmissionsByIntakeFormIdsResponse - name: intakeFormSubmissionCounts | type: array | description: Submission counts per intake form. - name: intakeFormId | type: string | description: Intake form GUID. - name: submissionCount | type: integer | description: Total number of submissions for the intake form. ``` ### Examples ### Count submissions by intake form IDs ```curl curl -X POST \ 'https://www.wixapis.com/intake-form-submissions/v1/intake-form-submissions/count' \ -H 'Authorization: ' \ -H 'Content-Type: application/json' \ -d '{ "intakeFormIds": [ "550e8400-e29b-41d4-a716-446655440000", "660e8400-e29b-41d4-a716-446655440001" ] }' ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.intakeForms.IntakeFormSubmissionsService.countSubmissionsByIntakeFormIds(intakeFormIds) Description: Counts intake form submissions by form GUIDs. Returns the total number of submissions per intake form. If you include a deleted intake form GUID in the request, that form is omitted from the response. Use this method for analytics, reporting, or checking if a form has submissions before deleting it. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: intakeFormIds Method parameters: param name: intakeFormIds | type: array | description: List of intake form GUIDs to count submissions for. | required: true Return type: PROMISE - name: intakeFormSubmissionCounts | type: array | description: Submission counts per intake form. - name: intakeFormId | type: string | description: Intake form GUID. - name: submissionCount | type: integer | description: Total number of submissions for the intake form. ``` ### Examples ### countSubmissionsByIntakeFormIds ```javascript import { intakeFormSubmissions } from '@wix/intake-forms'; async function countSubmissionsByIntakeFormIds(intakeFormIds) { const response = await intakeFormSubmissions.countSubmissionsByIntakeFormIds(intakeFormIds); }; ``` ### countSubmissionsByIntakeFormIds (with elevated permissions) ```javascript import { intakeFormSubmissions } from '@wix/intake-forms'; import { auth } from '@wix/essentials'; async function myCountSubmissionsByIntakeFormIdsMethod(intakeFormIds) { const elevatedCountSubmissionsByIntakeFormIds = auth.elevate(intakeFormSubmissions.countSubmissionsByIntakeFormIds); const response = await elevatedCountSubmissionsByIntakeFormIds(intakeFormIds); } ``` ### countSubmissionsByIntakeFormIds (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { intakeFormSubmissions } from '@wix/intake-forms'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { intakeFormSubmissions }, // Include the auth strategy and host as relevant }); async function countSubmissionsByIntakeFormIds(intakeFormIds) { const response = await myWixClient.intakeFormSubmissions.countSubmissionsByIntakeFormIds(intakeFormIds); }; ``` ---