Generally to use any Third Party application, First you need to go through the API documentation and integration details.
https://mailchimp.com/developer/marketing/api/
https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service
- Import the MailChimp HTML Template: Import the HTML file into AEMasCS. This can be done by creating a new component in AEM and using the HTML file as the component's structure.
- Create an AEM Form Based on the Template: Once the HTML file is imported, you can create a form based on this template. This involves mapping the form fields in the HTML file to the corresponding fields in the AEM form.
- Integrate with MailChimp API: To send the form data to MailChimp, you would need to integrate with the MailChimp API. This involves making a POST request to the MailChimp API with the form data whenever the form is submitted
Please go through MailChimp API document to find
how to authenticate with the MailChimp API,
how to make API requests, and
how to handle API responses.
https://mailchimp.com/developer/marketing/api/templates/
https://mailchimp.com/developer/marketing/guides/quick-start/#generate-your-api-key