jira.js
    Preparing search index...

    Function inviteUsers

    • Invite people to your organization. When you invite someone:

      • They’re given app roles according to your invitation.
      • They’re added to directories based on apps in your invitation.
      • They’re added to groups according to your invitation.
      • They receive an email invitation if the sendNotification field is set to true and the notificationText field contains a message to include in the email invitation.

      This API is only available to customers who have at least one paid subscription in their organization.

      Parameters

      • client: Client
      • parameters: {
            additionalGroups?: string[];
            emails: string[];
            notificationText?: string;
            orgId: string;
            permissionRules?: {
                resource: string;
                role: string;
                [key: string]: unknown;
            }[];
            sendNotification?: boolean;
        }
        • OptionaladditionalGroups?: string[]

          The groups you want to add users to from this invitation. Use the Get groups in an organization endpoint to find the group IDs.

        • emails: string[]

          Email addresses of the people you want to invite.

        • OptionalnotificationText?: string

          Add a message to your email invitation.

        • orgId: string

          Your organization has a unique ID. Find this ID in your Atlassian Administration URL or when you create your API key.

        • OptionalpermissionRules?: { resource: string; role: string; [key: string]: unknown }[]

          The access you want to give users from this invitation.

        • OptionalsendNotification?: boolean

          Set to true if you want to send an email invitation.

      • Optionaloptions: RequestOptions

      Returns Promise<
          {
              data?: {
                  email?: string;
                  id?: string;
                  results?: {
                      groupAssignmentResult?: {
                          group?: ...;
                          status?: ...;
                          statusReason?: ...;
                          [key: ...]: ...;
                      }[];
                      roleAssignmentResult?: {
                          resource?: ...;
                          role?: ...;
                          status?: ...;
                          statusReason?: ...;
                          [key: ...]: ...;
                      }[];
                      [key: string]: unknown;
                  }[];
                  [key: string]: unknown;
              }[];
              [key: string]: unknown;
          },
      >