Groups
Create a group in the current user's account. Only administrators are allowed to perform this action.
Example:
curl -X POST -H "X-Session-ID: 0123456789" -H "Content-Type: application/json" --data @data.json "https://lor.instructure.com/api/groups"
data.json:
{
"name": "The Group Name"
}
Session authentication. The session ID can be provided in any of the following ways: [Cookie: 'session'] [Header: 'x-session-id'] [Query parameter: 'session-id'] [Query parameter: first value of 'state'] [Body property: 'sessionId']
The desired name for the group
The newly created group
The unique identifier for the group
The name of the group
The account ID to which the group belongs
Bad Request
POST /api/groups HTTP/1.1
Host: lor.instructure.com
x-session-id: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 25
{
"name": "The Group Name"
}{
"id": "text",
"name": "text",
"accountId": "text"
}Gets a list of all the groups the user has access to. If the user is an admin it will return all the groups in the account.
Example:
curl -H "X-Session-ID: 0123456789" "https://lor.instructure.com/api/groups"
Session authentication. The session ID can be provided in any of the following ways: [Cookie: 'session'] [Header: 'x-session-id'] [Query parameter: 'session-id'] [Query parameter: first value of 'state'] [Body property: 'sessionId']
An array of the groups for the account
Bad Request
GET /api/groups HTTP/1.1
Host: lor.instructure.com
x-session-id: YOUR_API_KEY
Accept: */*
{
"items": [
{
"id": "text",
"name": "text",
"accountId": "text",
"isManager": true
}
]
}Update a group in the current user's account. Only an admin or manager of the group can perform this request.
Example:
curl -X PUT -H "X-Session-ID: 0123456789" -H "Content-Type: application/json" --data @data.json "https://lor.instructure.com/api/groups/:id"
data.json:
{
"name": "The Group Name"
}
Session authentication. The session ID can be provided in any of the following ways: [Cookie: 'session'] [Header: 'x-session-id'] [Query parameter: 'session-id'] [Query parameter: first value of 'state'] [Body property: 'sessionId']
The group id
The desired name for the group
The updated group
The unique identifier for the group
The name of the group
The account ID to which the group belongs
Bad Request
PUT /api/groups/{id} HTTP/1.1
Host: lor.instructure.com
x-session-id: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 25
{
"name": "The Group Name"
}{
"id": "text",
"name": "text",
"accountId": "text"
}Get a group by its ID. Only an admin or manager of the group can use this endpoint.
Example:
curl -H "X-Session-ID: 0123456789" "https://lor.instructure.com/api/groups/:id"
Session authentication. The session ID can be provided in any of the following ways: [Cookie: 'session'] [Header: 'x-session-id'] [Query parameter: 'session-id'] [Query parameter: first value of 'state'] [Body property: 'sessionId']
The group id
The group object
The unique identifier for the group
The name of the group
The account ID to which the group belongs
Bad Request
GET /api/groups/{id} HTTP/1.1
Host: lor.instructure.com
x-session-id: YOUR_API_KEY
Accept: */*
{
"id": "text",
"name": "text",
"accountId": "text"
}Deletes a group. Only Administrators are allowed to perform this action.
Example:
curl -X DELETE -H "X-Session-ID: 01234567890" "https://lor.instructure.com/api/groups/asdf"
Session authentication. The session ID can be provided in any of the following ways: [Cookie: 'session'] [Header: 'x-session-id'] [Query parameter: 'session-id'] [Query parameter: first value of 'state'] [Body property: 'sessionId']
The group id
No Content
No content
Bad Request
DELETE /api/groups/{id} HTTP/1.1
Host: lor.instructure.com
x-session-id: YOUR_API_KEY
Accept: */*
No content
Last updated
Was this helpful?