Add Member to Project
POST https://deploygate.com/api/organizations/{PROJECT_NAME}/members
Add new users to the Project as members. If the user has not registered with DeployGate, an invitation will be sent.
Path Params
| Name | Type | Required | Description |
|---|---|---|---|
| PROJECT_NAME | string | true | Project Name |
Body
| Name | Type | Required | Description |
|---|---|---|---|
| username | string | false | DeployGate username |
| string | false | Email address registered with DeployGate, or the email address to which an invitation will be sent |
Parameters in request body
When inviting a user, provide either username or email as a query parameter.
- When
usernameis specified, the DeployGate user whose username matches the specified value will be added as a member. - When
emailis specified- If the email address is already registered to a DeployGate user, that user will be added.
- If the email address is not yet registered, an invitation email will be sent to the specified email address. Follow the instructions in the invitation email to sign up, and once registration is complete, you will be automatically added to the group that invited you.
Example
curl \
-X POST \
--url "https://deploygate.com/api/organizations/${PROJECT_NAME}/members" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${API_TOKEN}" \
--form-string "email=${EMAIL}"
Result 200
{
"error": false,
"message": "${EMAIL} was invited to ${PROJECT_NAME}"
}
Result 400
{}