Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hub Generated] Review request for Microsoft.DevCenter to add version preview/2023-07-01-preview #24291

Merged
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
bd1080b
Adds base for updating Microsoft.DevCenter from version preview/2023-…
chrissmiller May 22, 2023
d71c9f7
Updates readme
chrissmiller May 22, 2023
e625958
Updates API version in new specs and examples
chrissmiller May 22, 2023
309bc2f
Add schedule and troubleshoot APIs, add generic id property, update e…
chrissmiller Jun 5, 2023
d78211e
Add troubleshoot example and update environment examples
chrissmiller Jun 5, 2023
8292390
Add ID to project
chrissmiller Jun 5, 2023
742db3e
Add environment operations API
chrissmiller Jun 5, 2023
8fe0c8a
Re-add last operation ID
chrissmiller Jun 5, 2023
7f196db
Run prettier
chrissmiller Jun 5, 2023
a862abe
Add ID to delay result
chrissmiller Jun 5, 2023
cff68ae
Add suppression for host parameters validation
chrissmiller Jun 5, 2023
5b6f0db
Remove last operation ID
chrissmiller Jun 12, 2023
b10c41a
Update with aligned operations API, URI property, file type log response
chrissmiller Jun 20, 2023
e001f36
Remove old examples
chrissmiller Jun 20, 2023
c41019c
Fix naming
chrissmiller Jun 20, 2023
eb9ee7e
Update TTL to 90 days on operations, add delete operationkind
chrissmiller Jun 20, 2023
d5aca43
Add sourceType
chrissmiller Jun 20, 2023
5820bdc
Remove old model
chrissmiller Jun 20, 2023
10c8727
Use an enum for status
chrissmiller Jun 20, 2023
30f653b
Consolidate on "sourceUri" for consistency with "uri" property
chrissmiller Jun 22, 2023
0d96762
Description updates
chrissmiller Jun 23, 2023
4dbaf49
Add NotStarted state
chrissmiller Jun 26, 2023
d301413
Add default response and missing LRO options to resolve LintDiff warn…
chrissmiller Jun 29, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,346 @@
{
"swagger": "2.0",
"info": {
"version": "2023-07-01-preview",
"title": "DevCenter"
},
"x-ms-parameterized-host": {
"hostTemplate": "{endpoint}",
"useSchemePrefix": false,
"parameters": [
{
"$ref": "devcenter.json#/parameters/EndpointParameter"
}
]
},
"schemes": [
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"security": [
{
"AADToken": [
"user_impersonation"
]
}
],
"securityDefinitions": {
"AADToken": {
"type": "oauth2",
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"flow": "implicit",
"description": "Azure Active Directory OAuth2 Flow",
"scopes": {
"user_impersonation": "impersonate your user account"
}
}
},
"paths": {
"/projects": {
"get": {
"tags": [
"Projects"
],
"description": "Lists all projects.",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/FilterParameter"
},
{
"$ref": "#/parameters/TopParameter"
}
],
"operationId": "DevCenter_ListProjects",
"responses": {
"200": {
"description": "OK. The request has succeeded.",
"schema": {
"$ref": "#/definitions/ProjectListResult"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-examples": {
"DevCenter_ListProjects": {
"$ref": "./examples/Projects_ListByDevCenter.json"
}
},
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/projects/{projectName}": {
"get": {
"tags": [
"Projects"
],
"description": "Gets a project.",
"parameters": [
{
"$ref": "#/parameters/ProjectNameMethodParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"operationId": "DevCenter_GetProject",
"responses": {
"200": {
"description": "OK. The request has succeeded.",
"schema": {
"$ref": "#/definitions/Project"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-examples": {
"DevCenter_GetProject": {
"$ref": "./examples/Projects_Get.json"
}
}
}
}
},
"definitions": {
"ProjectListResult": {
"description": "Results of the project list operation.",
"type": "object",
"properties": {
"value": {
"description": "Current page of results.",
"type": "array",
"items": {
"$ref": "#/definitions/Project"
}
},
"nextLink": {
"description": "URL to get the next set of results if there are any.",
"type": "string"
}
},
"required": [
"value"
]
},
"Project": {
"description": "Project details.",
"type": "object",
"properties": {
"uri": {
"description": "The unique URI of the project",
"type": "string"
},
"name": {
"type": "string",
"description": "Name of the project"
},
"description": {
"type": "string",
"description": "Description of the project."
},
"maxDevBoxesPerUser": {
"type": "integer",
"format": "int32",
"minimum": 0,
"description": "When specified, indicates the maximum number of Dev Boxes a single user can create across all pools in the project."
}
},
"required": [
"uri",
"name"
]
},
"CloudError": {
"x-ms-external": true,
"type": "object",
"required": [
"error"
],
"properties": {
"error": {
"description": "Error body",
"$ref": "#/definitions/CloudErrorBody"
}
},
"description": "An error response from the service."
},
"CloudErrorBody": {
"x-ms-external": true,
"description": "An error response from the service.",
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "string",
"description": "An identifier for the error. Codes are invariant and are intended to be consumed programmatically."
},
"message": {
"type": "string",
"description": "A message describing the error, intended to be suitable for display in a user interface."
},
"target": {
"type": "string",
"description": "The target of the particular error. For example, the name of the property in error."
},
"details": {
"type": "array",
"items": {
"$ref": "#/definitions/CloudErrorBody"
},
"description": "A list of additional details about the error."
}
}
},
"OperationStatus": {
"description": "The current status of an async operation",
"type": "object",
"properties": {
"id": {
"description": "Fully qualified ID for the operation status.",
"type": "string"
},
"name": {
"description": "The operation id name",
"type": "string"
},
"status": {
"description": "Provisioning state of the resource.",
"type": "string"
},
"resourceId": {
"description": "The id of the resource.",
"type": "string"
},
"startTime": {
"description": "The start time of the operation",
"type": "string",
"format": "date-time"
},
"endTime": {
"description": "The end time of the operation",
"type": "string",
"format": "date-time"
},
"percentComplete": {
"description": "Percent of the operation that is complete",
"type": "number",
"minimum": 0,
"maximum": 100
},
"properties": {
"description": "Custom operation properties, populated only for a successful operation.",
"type": "object"
},
"error": {
"description": "Operation Error message",
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "The error code."
},
"message": {
"type": "string",
"description": "The error message."
}
}
}
},
"required": [
"status"
]
}
},
"parameters": {
"ProjectNameParameter": {
"name": "projectName",
"description": "The DevCenter Project upon which to execute operations.",
"required": true,
"type": "string",
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9-_.]{2,62}$",
"minLength": 3,
"maxLength": 63,
"in": "path",
"x-ms-parameter-location": "client"
},
"ProjectNameMethodParameter": {
"name": "projectName",
"description": "The DevCenter Project upon which to execute operations.",
"required": true,
"type": "string",
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9-]{2,62}$",
"minLength": 3,
"maxLength": 63,
"in": "path",
"x-ms-parameter-location": "method"
},
"ApiVersionParameter": {
"name": "api-version",
"in": "query",
"required": true,
"type": "string",
"description": "The API version to be used with the HTTP request.",
"x-ms-parameter-location": "client"
},
"FilterParameter": {
"name": "filter",
"in": "query",
"description": "An OData filter clause to apply to the operation.",
"type": "string",
"required": false,
"x-ms-parameter-location": "method"
},
"TopParameter": {
"name": "top",
"in": "query",
"description": "The maximum number of resources to return from the operation. Example: 'top=10'.",
"type": "integer",
"format": "int32",
"required": false,
"x-ms-parameter-location": "method"
},
"UserIdParameter": {
"name": "userId",
"in": "path",
"required": true,
"x-ms-client-default": "me",
"type": "string",
"pattern": "^[a-zA-Z0-9]{8}-([a-zA-Z0-9]{4}-){3}[a-zA-Z0-9]{12}$|^me$",
"minLength": 2,
"maxLength": 36,
"description": "The AAD object id of the user. If value is 'me', the identity is taken from the authentication context.",
"x-ms-parameter-location": "method"
},
"EndpointParameter": {
"name": "endpoint",
"description": "The DevCenter-specific URI to operate on.",
"required": true,
"type": "string",
"in": "path",
"x-ms-skip-url-encoding": true,
"x-ms-parameter-location": "client"
}
}
}
Loading