Hello Everyone,
I’m trying to create an Automation which can detect if any of the admins in my env changes the account settings such as “Require Two-Factor Authentication (2FA)” but I’m unable to find the right way to get the current state of this and similar settings in the first place using an API.
Please share the API endpoint or SDK module, which can be helpful, I highly appreciate your help 
Best
Hi, @AdminPerimeters
Welcome to our community! This is a great question. There isn’t a specific endpoint for us to use. And we have an option depending on exactly what you need.
The Account Activity API has an endpoint titled — Get security activity for a HubSpot account GET/account-info/v3/activity/security
This endpoint returns the information from the in-app Security Audit export. This export contains the following details:
- Adding, removing, or requiring single sign-on (SSO) or two-factor authentication (2FA)
- Importing acceptance tests
- Exporting contacts or users
- Adding, removing, or impersonating users and admin
- Adding or removing admin permissions
- Deactivating or reactivating users
- Viewing, creating, or deactivating an API key
- Turning email tracking and attachment logging settings on or off
- Adding or removing email recipients from the Never Log list
- Performing a GDPR delete of a contact
- Installing integrations
- Sending manual registration emails or password reset emails
- Creating a payment account and updating information, account changes, or sending payment onboarding links.
- Creating, syncing, or deleting sandboxes
For each user action, the export will show:
-
- the time of the action
- the type of action
- the user’s email address
- the ID of the affected object
- the approximate location
- a link to the URL where the action was taken in the account
You could set up an app to poll this endpoint on a set frequency and then compare the results for Adding, removing, or requiring single sign-on (SSO) or two-factor authentication (2FA). The endpoint allows you to pass a timestamp and return only results after the timestamp. The limitation is this endpoint does not allow us to specify what is returned to the result. It’s all or nothing. You’ll need to search for the change and filter the response outside these specific API calls.
Have fun building! — Jaycee
Hello @Jaycee_Lewis, Is it possible to get this data with the Developer CMS account?
Looking forward to hearing from you soon.
Best