Creates a new Google Service Account with the provided details.
Creates and stores a Google Service Account record for the tenant's Google Enterprise, used for server-to-server authentication with Google's EMM APIs.
About Google Service Account Some Google EMM operations require server-to-server authentication via a Google Service Account. This endpoint registers that account's credential material with Esper so it can be used for those operations going forward.
Key Fields / Query Parameters
google_enterprise_id— ID of the Google enterprise this service account belongs tokey_id— Identifier for the service account keydata— Service account credential datais_active— Whether this service account should be treated as active
Common Use Cases
- Setting up server-to-server EMM authentication for a newly enrolled Google Enterprise
- Rotating a service account's credentials by creating a replacement record
- Recovering EMM automation after a previous service account was revoked
Best Practices
- Treat the data and public_data fields as sensitive credential material — avoid logging them
- Deactivate or remove old service account records when rotating credentials, to avoid ambiguity about which is active
- Confirm the new account works (via a test EMM API call) before decommissioning an older one
Workflow
- Obtain the new service account credentials from Google
- POST them to this endpoint to register the account with Esper
- Confirm the account is active via GET /v2/emm/accounts/ and test EMM automation
- Mock serverhttps://develop-api.esper.io/_mock/openapi/v2/emm/accounts/
- https://develop-api.esper.cloud/apihttps://develop-api.esper.cloud/api/v2/emm/accounts/
curl -i -X POST \
https://develop-api.esper.io/_mock/openapi/v2/emm/accounts/ \
-H 'Authorization: string' \
-H 'Content-Type: application/json' \
-d '{
"tenant_id": "string",
"google_enterprise_id": "string",
"name": "string",
"key_id": "string",
"type": 0,
"is_set": true,
"is_active": true,
"data": "string",
"public_data": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}'Response
{ "tenant_id": "string", "google_enterprise_id": "string", "name": "string", "key_id": "string", "type": 0, "is_set": true, "is_active": true, "data": "string", "public_data": "string", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" }