Based on the search results, there’s a native AEM Assets and Figma integration available that might help streamline your workflow. However, for your specific use case of comparing Figma designs with your module library and creating AEM pages, you’ll need a custom solution using the [Figma API](AEM Integration with Figma , like Creative Cloud - Adobe Experience League Community - 723316) and AEM’s REST APIs.
For the CSRF token issue you’re experiencing, you’ll need to:
• First make a GET request to your AEM instance to retrieve the CSRF token from the response headers
• Include this token in subsequent POST/PUT requests when creating pages or copying modules
• Use AEM’s Content Services API or Sling POST servlet to create pages and copy content
The community discussion on [automating content migration from Figma to AEM](Solved: Best Practices for Automating Content Migration fr... - Adobe Experience League Community - 769540) suggests this is a common challenge, and you might want to consider using AEM’s package manager API to handle module copying more efficiently than individual component operations.