Shelvesets - Get
In this article
Get a single deep shelveset.
GET https://{instance}/{collection}/_apis/tfvc/shelvesets?shelvesetId={shelvesetId}&api-version=5.0
GET https://{instance}/{collection}/_apis/tfvc/shelvesets?shelvesetId={shelvesetId}&requestData.includeLinks={requestData.includeLinks}&requestData.includeWorkItems={requestData.includeWorkItems}&requestData.includeDetails={requestData.includeDetails}&requestData.maxChangeCount={requestData.maxChangeCount}&requestData.maxCommentLength={requestData.maxCommentLength}&requestData.owner={requestData.owner}&requestData.name={requestData.name}&api-version=5.0
Name | In | Required | Type | Description |
---|---|---|---|---|
collection
|
path | True |
string |
The name of the Azure DevOps collection. |
instance
|
path | True |
string |
Azure DevOps server name ({server:port}) |
api-version
|
query | True |
string |
Version of the API to use. This should be set to '5.0' to use this version of the api. |
shelveset
|
query | True |
string |
Shelveset's unique ID |
request
|
query |
boolean |
Whether to include policyOverride and notes Only applies when requesting a single deep shelveset |
|
request
|
query |
boolean |
Whether to include the _links field on the shallow references. Does not apply when requesting a single deep shelveset object. Links will always be included in the deep shelveset. |
|
request
|
query |
boolean |
Whether to include workItems |
|
request
|
query |
integer (int32) |
Max number of changes to include |
|
request
|
query |
integer (int32) |
Max length of comment |
|
request
|
query |
string |
Shelveset's name |
|
request
|
query |
string |
Owner's ID. Could be a name or a guid. |
Name | Type | Description |
---|---|---|
200 OK |
successful operation |
Type:
oauth2
Flow:
accessCode
Authorization URL:
https://app.vssps.visualstudio.com/oauth2/authorize&response_type=Assertion
Token URL:
https://app.vssps.visualstudio.com/oauth2/token?client_assertion_type=urn:ietf:params:oauth:client-assertion-type:jwt-bearer&grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer
Name | Description |
---|---|
vso.code | Grants the ability to read source code and metadata about commits, changesets, branches, and other version control artifacts. Also grants the ability to search code and get notified about version control events via service hooks. |
Basic example |
Include |
Owner |
Shelveset by Id with max |
Shelveset |
top and skip |
With max |
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?shelvesetId=My first shelveset;fabrikamfiber16@hotmail.com&api-version=5.0
Sample response
{
"count": 4,
"value": [
{
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here is a really long comment describing this shelveset.",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "More changes",
"id": "More changes;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:29:45.91Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/More%20changes%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Doc updates",
"id": "Doc updates;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:27:25.18Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Doc%20updates%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Set this aside for now",
"id": "Set this aside for now;8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"owner": {
"id": "8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"displayName": "Chuck Reinhart",
"uniqueName": "fabrikamfiber3@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
},
"createdDate": "2014-03-24T20:32:25.37Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Set%20this%20aside%20for%20now%3b8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
}
]
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?shelvesetId=My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db&api-version=5.0
Sample response
{
"policyOverride": {
"policyFailures": []
},
"notes": [],
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here is a really long comment describing this shelveset.",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db",
"_links": {
"self": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
"changes": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/changes"
},
"workItems": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/workitems"
},
"owner": {
"href": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db"
}
}
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?api-version=5.0
Sample response
{
"count": 3,
"value": [
{
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here is a really long comment describing this shelveset.",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "More changes",
"id": "More changes;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:29:45.91Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/More%20changes%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Doc updates",
"id": "Doc updates;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:27:25.18Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Doc%20updates%3bd6245f20-2af8-44f4-9451-8107cb2767db"
}
]
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?shelvesetId=My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db&api-version=5.0
Sample response
{
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here i",
"commentTruncated": true,
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db",
"_links": {
"self": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
"changes": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/changes"
},
"workItems": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/workitems"
},
"owner": {
"href": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db"
}
}
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?shelvesetId=My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db&api-version=5.0
Sample response
{
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here is a really long comment describing this shelveset.",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db",
"_links": {
"self": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
"changes": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/changes"
},
"workItems": {
"href": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db/workitems"
},
"owner": {
"href": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db"
}
}
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?api-version=5.0
Sample response
{
"count": 2,
"value": [
{
"name": "Doc updates",
"id": "Doc updates;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:27:25.18Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Doc%20updates%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Set this aside for now",
"id": "Set this aside for now;8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"owner": {
"id": "8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"displayName": "Chuck Reinhart",
"uniqueName": "fabrikamfiber3@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
},
"createdDate": "2014-03-24T20:32:25.37Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Set%20this%20aside%20for%20now%3b8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
}
]
}
Sample request
GET https://{instance}/fabrikam/_apis/tfvc/shelvesets?api-version=5.0
Sample response
{
"count": 4,
"value": [
{
"name": "My first shelveset",
"id": "My first shelveset;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:37:52.277Z",
"comment": "Here i",
"commentTruncated": true,
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/My%20first%20shelveset%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "More changes",
"id": "More changes;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:29:45.91Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/More%20changes%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Doc updates",
"id": "Doc updates;d6245f20-2af8-44f4-9451-8107cb2767db",
"owner": {
"id": "d6245f20-2af8-44f4-9451-8107cb2767db",
"displayName": "Normal Paulk",
"uniqueName": "fabrikamfiber16@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/d6245f20-2af8-44f4-9451-8107cb2767db",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=d6245f20-2af8-44f4-9451-8107cb2767db"
},
"createdDate": "2014-07-18T03:27:25.18Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Doc%20updates%3bd6245f20-2af8-44f4-9451-8107cb2767db"
},
{
"name": "Set this aside for now",
"id": "Set this aside for now;8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"owner": {
"id": "8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"displayName": "Chuck Reinhart",
"uniqueName": "fabrikamfiber3@hotmail.com",
"url": "https://fabrikam:8080/tfs/_apis/Identities/8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d",
"imageUrl": "https://fabrikam:8080/tfs/_api/_common/identityImage?id=8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
},
"createdDate": "2014-03-24T20:32:25.37Z",
"url": "https://fabrikam:8080/tfs/_apis/tfvc/shelvesets/Set%20this%20aside%20for%20now%3b8c8c7d32-6b1b-47f4-b2e9-30b477b5ab3d"
}
]
}
Name | Description |
---|---|
Associated |
|
Checkin |
|
Identity |
|
Item |
|
Item |
|
Reference |
The class to represent a collection of REST reference links. |
Tfvc |
|
Tfvc |
|
Tfvc |
|
Tfvc |
|
Tfvc |
This is the deep shelveset class |
Version |
The type of change that was made to the item. |
Name | Type | Description |
---|---|---|
assignedTo |
string |
|
id |
integer (int32) |
Id of associated the work item. |
state |
string |
|
title |
string |
|
url |
string |
REST Url of the work item. |
webUrl |
string |
|
workItemType |
string |
Name | Type | Description |
---|---|---|
name |
string |
|
value |
string |
Name | Type | Description |
---|---|---|
_links |
This field contains zero or more interesting links about the graph subject. These links may be invoked to obtain additional relationships or more detailed information about this graph subject. |
|
descriptor |
string |
The descriptor is the primary way to reference the graph subject while the system is running. This field will uniquely identify the same graph subject across both Accounts and collections. |
directoryAlias |
string |
|
displayName |
string |
This is the non-unique display name of the graph subject. To change this field, you must alter its value in the source provider. |
id |
string |
|
imageUrl |
string |
|
inactive |
boolean |
|
isAadIdentity |
boolean |
|
isContainer |
boolean |
|
isDeletedInOrigin |
boolean |
|
profileUrl |
string |
|
uniqueName |
string |
|
url |
string |
This url is the full route to the source resource of this graph subject. |
Name | Type | Description |
---|---|---|
content |
string |
|
contentType |
Value | Description |
---|---|
base64Encoded | |
rawText |
The class to represent a collection of REST reference links.
Name | Type | Description |
---|---|---|
links |
object |
The readonly view of the links. Because Reference links are readonly, we only want to expose them as read only. |
Name | Type | Description |
---|---|---|
changeType |
The type of change that was made to the item. |
|
item |
string (T) |
Current version. |
mergeSources |
List of merge sources in case of rename or branch creation. |
|
newContent |
Content of the item after the change. |
|
pendingVersion |
integer (int32) |
Version at which a (shelved) change was pended against |
sourceServerItem |
string |
Path of the item on the server. |
url |
string |
URL to retrieve the item. |
Name | Type | Description |
---|---|---|
isRename |
boolean |
Indicates if this a rename source. If false, it is a merge source. |
serverItem |
string |
The server item of the merge source |
versionFrom |
integer (int32) |
Start of the version range |
versionTo |
integer (int32) |
End of the version range |
Name | Type | Description |
---|---|---|
message |
string |
|
policyName |
string |
Name | Type | Description |
---|---|---|
comment |
string |
|
policyFailures |
This is the deep shelveset class
Name | Type | Description |
---|---|---|
_links |
The class to represent a collection of REST reference links. |
|
changes | ||
comment |
string |
|
commentTruncated |
boolean |
|
createdDate |
string (date-time) |
|
id |
string |
|
name |
string |
|
notes | ||
owner | ||
policyOverride | ||
url |
string |
|
workItems |
The type of change that was made to the item.
Value | Description |
---|---|
add | |
all | |
branch | |
delete | |
edit | |
encoding | |
lock | |
merge | |
none | |
property | |
rename | |
rollback | |
sourceRename | |
targetRename | |
undelete |