Docs/User API/Flows/Update join organization

Update join organization invitation

Preview
PATCH/user/v1/flows/{flowId}:updateJoinOrganization

Update a join organization flow.

path parameters

  • flowId

    string

    Required

    The identifier of the flow.

body parameters

  • roleId

    string

    The identifier of the role.

Returns

  • id

    string

    The system-assigned identifier of the flow.

  • state

    enum

    The current state of the flow.

    Possible values:
    START_PENDINGSTARTEDCOMPLETEDCANCELEDEXPIRED
  • stateReason

    string

    The code that best describes the reason for the state.

  • type

    enum

    The flow type.

    Possible values:
    JOIN_ORGANIZATIONSIGNUP
  • organization

    Organization

    The target organization for the flow.

  • user

    User

    The target user for the flow.

  • creator

    User

    The user who created the flow.

  • joinOrganization

    JoinOrganizationFlow

    The join organization flow type specific data.

  • signup

    SignupFlow

    The signup flow type specific data.

  • expireTime

    date-time

    The time the flow will expire.

  • createTime

    date-time

    The creation time of the flow.

curl https://api.userhub.com/user/v1/flows/string:updateJoinOrganization \
  -H "UserHub-Api-Key: $USERHUB_USER_KEY" \
  -H "Authorization: Bearer $USER_ACCESS_TOKEN" \
  -X PATCH \
  --json '{
    "roleId": "role_51jav4KK"
  }'
Response bodyJSON
{
  "id": "flow_3on5rHNG5aMGao",
  "state": "START_PENDING",
  "type": "JOIN_ORGANIZATION",
  "organization": {
    "id": "org_28seyVGVL1got6",
    "displayName": "Acme Inc",
    "email": "[email protected]",
    "emailVerified": true,
    "imageUrl": "https://example.com/acme.jpg",
    "memberCount": 0
  },
  "creator": {
    "id": "usr_EHTXpuz9rs8TCU",
    "displayName": "Jane Doe",
    "email": "[email protected]",
    "emailVerified": true,
    "imageUrl": "https://example.com/jane.jpg"
  },
  "joinOrganization": {
    "email": "[email protected]",
    "role": {
      "id": "role_51jav4KK",
      "uniqueId": "admin",
      "displayName": "Admin",
      "type": "MEMBER",
      "seatPolicy": "DEFAULT",
      "permissionSets": [
        "billing.readonly",
        "members.readwrite"
      ],
      "default": false
    }
  },
  "expireTime": "2025-06-15T13:00:00Z",
  "createTime": "2025-05-15T13:00:00Z"
}
PreviousSend a join organization invitation
NextSend a signup invitation

Build software thatmonetizes
$

Subscribe to monthly product updates

© 2025 UserHub

Integrations

    UserHub & Auth0UserHub & Stripe BillingUserHub & Google CloudUserHub & FirebaseUserHub & custom auth