Invitations
Invitations allow you to invite users as people within a household. The Elements API refers to these types of invitations as ClientInvitations, allowing for additional invitation types in the future.
The ClientInvitation model
- Name
id- Type
- ID!
- Description
The unique identifier for the invitation.
- Name
createdAt- Type
- Time!
- Description
ISO-8601 timestamp of when this
ClientInvitationwas created.
- Name
updatedAt- Type
- Time!
- Description
ISO-8601 timestamp of when this
ClientInvitationwas last updated.
- Name
firmID- Type
- ID!
- Description
The unique identifier for the firm that owns this
ClientInvitation.
- Name
clientID- Type
- ID!
- Description
The unique identifier for the client the person is being invited into.
- Name
householdID- Type
- ID!
- Description
The unique identifier for the household the person is being invited into.
- Name
inviteeEmail- Type
- String!
- Description
The email address of the person being invited.
- Name
inviteeGivenName- Type
- String!
- Description
The given name of the person being invited.
- Name
inviteeFamilyName- Type
- String!
- Description
The family name of the person being invited.
- Name
status- Type
- InvitationStatus!
- Description
The status of the invitation. This is an enum with possible values being
PENDINGandACCEPTED.
- Name
acceptedAt- Type
- Time
- Description
ISO-8601 timestamp of when this
ClientInvitationwas accepted.nullif the invitation has not been accepted.
Querying client invitations
This query allows you to fetch all the client invitations for a firm. You can use this to display a list of pending invitations, or to check if a person has already been invited to a household.
Required arguments
- Name
firmID- Type
- ID!
- Description
The ID for the firm you want to fetch clients for.
Optional arguments
- Name
cursor- Type
- String
- Description
A cursor to fetch the next page of results.
Request
query ClientInvitations($firmID: ID!, $cursor: String) {
clientInvitationsForFirm(firmID: $firmID, cursor: $cursor) {
items {
id
createdAt
updatedAt
firmID
clientID
householdID
inviteeEmail
inviteeGivenName
inviteeFamilyName
status
acceptedAt
}
pageInfo {
hasNextPage
endCursor
}
}
}