# Create an invite

post ` https://app.mk.io/api/v1/organization/invites`

This endpoint allows you to create a new invitation which will grant a user access to this organization's resources within MK.IO.

You can include a comment which will be visible against this user's record when they accept the invitation, e.g. "Contractor for project Delphi".

RBAC Capability Required: `core.invite.create`

## Authentication

Authorization Bearer

Bearer authentication of the form `Bearer <token>`, where token is your
auth token.

## Request

This endpoint expects an object.

specobject [InviteSpecSchema](https://docs.mediakind.com/api-reference/management-api/schemas/invitespecschema) Required

### Specification

Show 6 propertiesHide 6 properties

- **comment**  `string` Required  
  Comment to explain why the user has been invited to collaborate with your organization  
- **email**  `string` Required  
  Email of the user to be invited  
- **teams**  `list of strings` Optional  
  List of team names to add this user to when they accept.

## Response

**201 OK**

- **kind**  `string` Optional  
  The kind of record.  
- **metadata**  `object` [InviteMetadataSchema](https://docs.mediakind.com/api-reference/management-api/schemas/invitemetadataschema) Optional

### Metadata

Show 2 propertiesHide 2 properties

- **created**  `string` Optional  format: date-time  
  The time when the resource was created  
- **id**  `string` Required  format: uuid  
  The ID of the resource  
- **spec**  `object` [InviteSpecSchema](https://docs.mediakind.com/api-reference/management-api/schemas/invitespecschema) Required

### Specification

Show 6 propertiesHide 6 properties

- **comment**  `string` Required  
  Comment to explain why the user has been invited to collaborate with your organization  
- **email**  `string` Required  
  Email of the user to be invited  
- **invitedByEmail**  `string` Required  
  Contact email of user who made the invite  
- **invitedByName**  `string` Required  
  Name of user who made the invite  
- **organizationName**  `string` Required  
  Name of the organization the invite refers to  
- **teams**  `list of strings` Optional  
  List of team names to add this user to when they accept.

## Errors

**400 Bad Request**

- **error**  `object` [ErrorDetail](https://docs.mediakind.com/api-reference/management-api/schemas/errordetail) Required  
  Pertinent information about the error

### Show 3 propertiesHide 3 properties

- **code**  `string` Required  
  The error code.  
- **detail**  `string` Required  
  The error message.  
- **extraDetail**  `map from strings to any` Optional  
  Extra information regarding this error.  
- **ref**  `string` Required  
  A reference to the request that caused the error.  
- **status**  `integer` Required  
  The HTTP status code

**401 Unauthorized**

... (similar error structure continues for 403, 404, 409, 429, 500 with only status text and details differing)
