Skip to content

Upload the data to be upserted in Okta

Request

OAuth 2.0 scope:
  • okta.identitySources.manage

Uploads entities that need to be inserted or updated in Okta from the identity source for the given session

Path
identitySourceIdstringrequired

The ID of the identity source for which the session is created

Example:0oa3l6l6WK6h0R0QW0g4
sessionIdstringrequired

The ID of the identity source session

Example:aps1qqonvr2SZv6o70h8
Bodyapplication/json
entityTypestring

The type of data to upsert into the session. Currently, only USERS is supported.

Value:"USERS"
profilesArray of objects

Array of user profiles to be uploaded

curl -i -X POST \
  https://subdomain.okta.com/api/v1/identity-sources/0oa3l6l6WK6h0R0QW0g4/sessions/aps1qqonvr2SZv6o70h8/bulk-upsert \
  -H 'Content-Type: application/json' \
  -d '{
    "entityType": "USERS",
    "profiles": [
      {
        "externalId": "EXT123456784C2IF",
        "profile": {
          "userName": "isaac.brock@example.com",
          "firstName": "Isaac",
          "lastName": "Brock",
          "email": "isaac.brock@example.com",
          "secondEmail": "isaac2.brock@example.com",
          "mobilePhone": "123-456-7890",
          "homeAddress": "10800 NE 8th St #600, Bellevue, WA 98004"
        }
      },
      {
        "externalId": "EXT123456784C3IF",
        "profile": {
          "userName": "jane.smith@example.com",
          "firstName": "Jane",
          "lastName": "Smith",
          "email": "jane.smith@example.com",
          "secondEmail": "jane2.smith@example.com",
          "mobilePhone": "555-123-4567",
          "homeAddress": "Seattle, WA 98101"
        }
      }
    ]
  }'

Responses

Accepted

Response
No content