Available methods:
Required API scope: profile
Optional API scope: profile:read_private
GET /api/v1/user
{
"guid": "5cebd150b82e0133e40c406c8f31e210",
"name": "Bob Testing",
"searchable": true,
"show_profile_info": true,
"birthday": "1984-01-02",
"diaspora_id": "bob@example.com",
"gender": "Example",
"location": "World",
"bio": "Lorem ipsum **dolor sit amet**, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat!",
"avatar": {
"large": "http://example.com/uploads/images/thumb_large_0fc4bbc68f744c27ed80.jpg",
"medium": "http://example.com/uploads/images/thumb_medium_0fc4bbc68f744c27ed80.jpg",
"small": "http://example.com/uploads/images/thumb_small_0fc4bbc68f744c27ed80.jpg"
},
"tags": [
"bobclub",
"development",
"diaspora"
]
}
No specific errors for this API endpoint.
Required API scope: profile:modify
PATCH /api/v1/user
{
"location": "My home!",
"name": "Bob Anonymous"
}
Name | Type | Description |
---|---|---|
bio | string | The profiles long bio text. |
birthday | date | The users birthday. ISO 8601, date only |
gender | string | The profiles gender. |
location | string | The users location. |
name | string | The new profile name. |
nsfw | boolean | Whether the profile should be marked as NSFW. |
searchable | boolean | Whether the profile should be searchable via the profile name or not. |
show_profile_info | boolean | whether the public info should be publicly visible or not. |
tags | array | Up to five tags to tag the profile with. |
{
"guid": "5cebd150b82e0133e40c406c8f31e210",
"name": "Bob Anonymous",
"searchable": true,
"show_profile_info": true,
"birthday": "1984-01-02",
"diaspora_id": "bob@example.com",
"gender": "Example",
"location": "My home!",
"bio": "Lorem ipsum **dolor sit amet**, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat!",
"avatar": {
"large": "http://example.com/uploads/images/thumb_large_0fc4bbc68f744c27ed80.jpg",
"medium": "http://example.com/uploads/images/thumb_medium_0fc4bbc68f744c27ed80.jpg",
"small": "http://example.com/uploads/images/thumb_small_0fc4bbc68f744c27ed80.jpg"
},
"tags": [
"bobclub",
"development",
"diaspora"
]
}
Status code | Error reason |
---|---|
400 | Wrong value of a parameter |
Please note that the amount of information you retrieve from this request depends on whether the requested person shares with the currently authenticated user or not.
Required API scope: public:read
Optional API scope: contacts:read
GET /api/v1/users/:person_guid
{
"guid": "f50ffc00b188013355e3705681972339",
"name": "Alice Testing",
"birthday": "1984-01-02",
"diaspora_id": "alice@example.com",
"gender": "Example",
"location": "My home!",
"bio": "Lorem ipsum **dolor sit amet**, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat!",
"blocked": false,
"avatar": {
"large": "http://example.com/uploads/images/thumb_large_0fc4bbc68f744c27ed80.jpg",
"medium": "http://example.com/uploads/images/thumb_medium_0fc4bbc68f744c27ed80.jpg",
"small": "http://example.com/uploads/images/thumb_small_0fc4bbc68f744c27ed80.jpg"
},
"tags": [
"development",
"diaspora"
],
"relationship": {
"receiving": true,
"sharing": false
},
"aspects": [
{
"id": 1,
"name": "Family"
}
]
}
Status code | Error reason |
---|---|
404 | User with provided guid could not be found |
Required API scope: public:read
Optional API scope: private:read
GET /api/v1/users/:person_guid/posts
[
{
"guid": "83d406e0b9b20133e40c406c8f31e210",
"created_at": "2016-02-20T03:46:57.955Z",
"post_type": "StatusMessage",
"title": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a di...",
"body": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor.",
"provider_display_name": "ExampleApp",
"public": true,
"nsfw": false,
"author": {
"guid": "f50ffc00b188013355e3705681972339",
"diaspora_id": "alice@example.com",
"name": "Alice Testing",
"avatar": "http://example.com/uploads/images/thumb_medium_83abe5319ef830c2bd84.jpg"
},
"interaction_counters": {
"comments": 14,
"likes": 42,
"reshares": 9
},
"own_interaction_state": {
"liked": false,
"reshated": false,
"subscribed": false
}
},
{
"guid": "466738b0b9c30133e40e406c8f31e210",
"created_at": "2016-02-20T05:47:02.694Z",
"post_type": "StatusMessage",
"title": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a di...",
"body": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor.",
"public": true,
"nsfw": false,
"author": {
"guid": "f50ffc00b188013355e3705681972339",
"diaspora_id": "alice@example.com",
"name": "Alice Testing",
"avatar": "http://example.com/uploads/images/thumb_medium_83abe5319ef830c2bd84.jpg"
},
"interaction_counters": {
"comments": 3,
"likes": 1,
"reshares": 0
},
"own_interaction_state": {
"liked": false,
"reshated": false,
"subscribed": false
}
}
]
Status code | Error reason |
---|---|
404 | User with provided guid could not be found |
Required API scope: public:read
Optional API scope: private:read
GET /api/v1/users/:person_guid/photos
[
{
"guid": "0a992a10b9db0133e40e406c8f31e210",
"post": "b50abae085ff0134029244b301d53d2d",
"created_at": "2016-11-06T03:43:03.382Z",
"dimensions": {
"height": 1200,
"width": 1600
},
"sizes": {
"raw": "http://example.com/uploads/images/f6ce0597695a878c4663.jpg",
"large": "http://example.com/uploads/images/scaled_full_f6ce0597695a878c4663.jpg",
"medium": "http://example.com/uploads/images/thumb_medium_f6ce0597695a878c4663.jpg",
"small": "http://example.com/uploads/images/thumb_small_f6ce0597695a878c4663.jpg"
}
},
{
"guid": "114999c0b9db0133e40e406c8f31e210",
"post": "c32c73a085ff0134029244b301d53d2d",
"created_at": "2016-11-06T03:42:27.807Z",
"dimensions": {
"height": 1200,
"width": 1600
},
"sizes": {
"raw": "http://example.com/uploads/images/c384f99eda7f19dfe78c.jpg",
"large": "http://example.com/uploads/images/scaled_full_c384f99eda7f19dfe78c.jpg",
"medium": "http://example.com/uploads/images/thumb_medium_c384f99eda7f19dfe78c.jpg",
"small": "http://example.com/uploads/images/thumb_small_c384f99eda7f19dfe78c.jpg"
}
}
]
Status code | Error reason |
---|---|
404 | User with provided guid could not be found |
Required API scope: contacts:modify
.
POST /api/v1/users/:person_guid/block
Status: 201 Created
Status code | Error reason |
---|---|
404 | User with provided guid could not be found |
409 | Block already exists |
Required API scope: contacts:modify
.
DELETE /api/v1/users/:person_guid/block
Status: 204 No Content
Status code | Error reason |
---|---|
404 | User with provided guid could not be found |
410 | Block doesn’t exist |