Skip to content

Commit

Permalink
docs: *_invitation life cycle clarification (#756)
Browse files Browse the repository at this point in the history
* docs(project_invitation): add notes on invite life cycle

* docs(org_invitation): add notes on invite life cycle

* docs(org_invitation): integrate existing note

* docs(project_invitation): match org invitation note

* docs(org_invitation): fix reference to project

* doc: clarify clarification for more clarity

Thanks for the suggestions!

Co-authored-by: Melissa Plunkett <themantissa@users.noreply.github.com>

Co-authored-by: Melissa Plunkett <themantissa@users.noreply.github.com>
  • Loading branch information
morey-tech and themantissa authored Jun 17, 2022
1 parent da8aa46 commit 80d231a
Showing 2 changed files with 16 additions and 5 deletions.
13 changes: 8 additions & 5 deletions website/docs/r/org_invitation.html.markdown
Original file line number Diff line number Diff line change
@@ -20,6 +20,11 @@ The [MongoDB Documentation](https://docs.atlas.mongodb.com/reference/user-roles/
* ORG_READ_ONLY
* ORG_MEMBER

~> **IMPORTANT:** This resource is only for managing invitations, not for managing the Atlas User being invited. Possible provider behavior depending on the invitee's action:
* If the user has not yet accepted the invitation, the provider leaves the invitation as is.
* If the user has accepted the invitation and is now an organization member, the provider will remove the invitation from the Terraform state. The invitation must then be removed from the Terraform resource configuration.
* If the user accepts the invitation and then leaves the organization, the provider will re-add the invitation if the resource definition is not removed from the Terraform configuration.

## Example Usages

```terraform
@@ -69,13 +74,11 @@ In addition to the arguments, this resource exports the following attributes:
* `invitation_id` - Unique 24-hexadecimal digit string that identifies the invitation in Atlas.
* `inviter_username` - Atlas user who invited `username` to the organization.

> **NOTE**: Possible provider behavior depending on the invitee's action:
>* If the user has not yet accepted the invitation, the provider leaves the invitation as is.
>* If the user has accepted the invitation and is now an organization member, the provider will remove the invitation from the Terraform state. The invitation must then be removed from the Terraform resource configuration.
>* If the user accepts the invitation and then leaves the organization, the provider will re-add the invitation if the resource definition is not removed from the Terraform configuration.
## Import

~> **IMPORTANT:**
An organization invitation can **not** be imported once it has been accepted.

Import a user's invitation to an organization by separating the `org_id` and the `username` with a hyphen:


8 changes: 8 additions & 0 deletions website/docs/r/project_invitation.html.markdown
Original file line number Diff line number Diff line change
@@ -23,6 +23,11 @@ The [MongoDB Documentation](https://docs.atlas.mongodb.com/reference/user-roles/

-> **NOTE:** Groups and projects are synonymous terms. You may find GROUP-ID in the official documentation.

~> **IMPORTANT:** This resource is only for managing invitations, not for managing the Atlas User being invited. Possible provider behavior depending on the invitee's action:
* If the user has not yet accepted the invitation, the provider leaves the invitation as is.
* If the user has accepted the invitation and is now a project member, the provider will remove the invitation from the Terraform state. The invitation must then be removed from the Terraform resource configuration.
* If the user accepts the invitation and then leaves the project, the provider will re-add the invitation if the resource definition is not removed from the Terraform configuration.

## Example Usages

```terraform
@@ -65,6 +70,9 @@ In addition to all arguments above, the following attributes are exported:

## Import

~> **IMPORTANT:**
A project invitation can **not** be imported once it has been accepted.

Import a user's invitation to a project by separating the `project_id` and the `username` with a hyphen:

```

0 comments on commit 80d231a

Please sign in to comment.