Skip to main content
POST
/
organizations
/
{orgId}
/
invitations
Invite User to Organization
curl --request POST \
  --url https://api.m3ter.com/organizations/{orgId}/invitations \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "firstName": "<string>",
  "lastName": "<string>",
  "email": "[email protected]",
  "m3terUser": true,
  "version": 123,
  "contactNumber": "<string>",
  "permissionPolicyIds": [
    "<string>"
  ],
  "dtEndAccess": "2023-11-07T05:31:56Z",
  "dtExpiry": "2023-11-07T05:31:56Z"
}
'
{
  "id": "<string>",
  "version": 123,
  "email": "<string>",
  "permissionPolicyIds": [
    "<string>"
  ],
  "firstName": "<string>",
  "lastName": "<string>",
  "dtEndAccess": "2023-11-07T05:31:56Z",
  "dtExpiry": "2023-11-07T05:31:56Z",
  "invitingPrincipalId": "<string>",
  "accepted": true,
  "dtCreated": "2023-11-07T05:31:56Z",
  "dtLastModified": "2023-11-07T05:31:56Z",
  "createdBy": "<string>",
  "lastModifiedBy": "<string>"
}

Authorizations

Authorization
string
header
required

m3ter supports machine to machine authentication using the clientCredentials OAuth2 flow.

The authorizationCode flow controls access for human users via the m3ter Console application.

Path Parameters

orgId
string
required

UUID of the Organization. The Organization represents your company as a direct customer of the m3ter service.

Body

application/json
firstName
string
required
Required string length: 1 - 100
lastName
string
required
Required string length: 1 - 100
email
string<email>
required
Minimum string length: 1
m3terUser
boolean
version
integer<int64>
contactNumber
string
Maximum string length: 50
permissionPolicyIds
string[]

The IDs of the permission policies the invited user has been assigned. This controls the access rights and privileges that this user will have when working in the m3ter Organization.

dtEndAccess
string<date-time>

The date when access will end for the user (in ISO-8601 format). Leave blank for no end date, which gives the user permanent access.

dtExpiry
string<date-time>

The date when the invite expires (in ISO-8601 format). After this date the invited user can no longer accept the invite. By default, any invite is valid for 30 days from the date the invite is sent.

Response

Returns the Invitation

id
string
required

The UUID of the entity.

version
integer<int64>

The version number:

  • Create: On initial Create to insert a new entity, the version is set at 1 in the response.
  • Update: On successful Update, the version is incremented by 1 in the response.
email
string

The email address of the invitee. The invitation will be sent to this email address.

permissionPolicyIds
string[]

The IDs of the permission policies the invited user has been assigned. This controls the access rights and privileges that this user will have when working in the m3ter Organization.

firstName
string

The first name of the invitee.

lastName
string

The surname of the invitee.

dtEndAccess
string<date-time>

The date that access will end for the user (in ISO-8601 format). If this is blank, there is no end date meaning that the user has permanent access.

dtExpiry
string<date-time>

The date when the invite expires (in ISO-8601 format). After this date the invited user can no longer accept the invite. By default, any invite is valid for 30 days from the date the invite is sent.

invitingPrincipalId
string

The UUID of the user who sent the invite.

accepted
boolean

Boolean indicating whether the user has accepted the invitation.

  • TRUE - the invite has been accepted.
  • FALSE - the invite has not yet been accepted.
dtCreated
string<date-time>

The DateTime when the invitation was created (in ISO-8601 format).

dtLastModified
string<date-time>

The DateTime when the invitation was last modified (in ISO-8601 format).

createdBy
string

The UUID of the user who created the invitation.

lastModifiedBy
string

The UUID of the user who last modified the invitation.