Get Pending Collaborations

Guides Collaborations Get Pending Collaborations
Edit this page

Get Pending Collaborations

To get the pending collaborations for a user, call the GET /collaborations API with a status of pending.

cURL
curl -i -X GET "https://api.box.com/2.0/collaborations?status=pending" \
     -H "Authorization: Bearer <ACCESS_TOKEN>"
Java
Collection<BoxCollaboration.Info> pendingCollaborations =
    BoxCollaboration.getPendingCollaborations(api);
Python
pending_collaborations = client.get_pending_collaborations()
for pending_collaboration in pending_collaborations:
    print('Collaboration {0} is pending'.format(pending_collaboration.id))
iOS
let iterator = client.collaborations.listPendingForEnterprise()
iterator.next { result in
    switch result {
    case let .success(page):
        for collaboration in page.entries {
            print("Collaboration created by \(collaboration.createdBy?.name)")
        }

    case let .failure(error):
        print(error)
    }
}

This only returns the current list of pending collaborations for a user. This API does not allow for returning all collaborations for a user.