Skip to content

Commit

Permalink
Search: Adding new data plane Swagger specs for API version 2016-09-01 (
Browse files Browse the repository at this point in the history
Azure#756)

For now, these are identical to the 2015-02-28-Preview specs except for the
version number, and all external URLs that pointed to azure.com or MSDN now
point to docs.microsoft.com.

GS >> I'm merging this because it's fundamentally the same as the previous version; updates are in docs and some V2 version of model types.
  • Loading branch information
brjohnstmsft authored and fearthecowboy committed Nov 29, 2016
1 parent e658f6f commit 334f0d4
Show file tree
Hide file tree
Showing 2 changed files with 4,086 additions and 0 deletions.
289 changes: 289 additions & 0 deletions search/2016-09-01/swagger/searchindex.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,289 @@
{
"swagger": "2.0",
"info": {
"title": "SearchIndexClient",
"description": "Client that can be used to query an Azure Search index and upload, merge, or delete documents.",
"version": "2016-09-01",
"x-ms-code-generation-settings": {
"useDateTimeOffset": true,
"syncMethods": "None"
}
},
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"paths": {
"/docs/$count": {
"get": {
"tags": [
"DocumentsProxy"
],
"operationId": "DocumentsProxy_Count",
"description": "Queries the number of documents in the Azure Search index.",
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/Count-Documents"
},
"parameters": [
{
"name": "client-request-id",
"in": "header",
"required": false,
"type": "string",
"format": "uuid",
"description": "The tracking ID sent with the request to help with debugging.",
"x-ms-client-request-id": true,
"x-ms-parameter-grouping": { "name": "search-request-options" }
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"x-ms-request-id": "request-id",
"responses": {
"200": {
"description": "",
"schema": {
"type": "integer",
"format": "int64"
}
}
}
}
}
},
"definitions": {
"IndexingResult": {
"properties": {
"key": {
"type": "string",
"readOnly": true,
"description": "The key of a document that was in the indexing request."
},
"errorMessage": {
"type": "string",
"readOnly": true,
"description": "The error message explaining why the indexing operation failed for the document identified by the key; null if indexing succeeded."
},
"status": {
"x-ms-client-name": "Succeeded",
"type": "boolean",
"readOnly": true,
"description": "A value indicating whether the indexing operation succeeded for the document identified by the key."
},
"statusCode": {
"type": "integer",
"format": "int32",
"readOnly": true,
"description": "The status code of the indexing operation. Possible values include: 200 for a successful update or delete, 201 for successful document creation, 400 for a malformed input document, 404 for document not found, 409 for a version conflict, 422 when the index is temporarily unavailable, or 503 for when the service is too busy."
}
},
"description": "Status of an indexing operation for a single document.",
"x-ms-external": true
},
"DocumentIndexResult": {
"properties": {
"value": {
"x-ms-client-name": "Results",
"type": "array",
"readOnly": true,
"items": {
"$ref": "#/definitions/IndexingResult"
},
"description": "The list of status information for each document in the indexing request."
}
},
"description": "Response containing the status of operations for all documents in the indexing request."
},
"IndexActionType": {
"type": "string",
"enum": [
"upload",
"merge",
"mergeOrUpload",
"delete"
],
"x-ms-enum": { "name": "IndexActionType" },
"description": "Specifies the operation to perform on a document in an indexing batch."
},
"SearchMode": {
"type": "string",
"enum": [
"any",
"all"
],
"x-ms-enum": { "name": "SearchMode" },
"description": "Specifies whether any or all of the search terms must be matched in order to count the document as a match."
},
"QueryType": {
"type": "string",
"enum": [
"simple",
"full"
],
"x-ms-enum": { "name": "QueryType" },
"description": "Specifies the syntax of the search query. The default is 'simple'. Use 'full' if your query uses the Lucene query syntax."
},
"SearchParametersPayload": {
"properties": {
"count": {
"type": "boolean",
"description": "A value that specifies whether to fetch the total count of results. Default is false. Setting this value to true may have a performance impact. Note that the count returned is an approximation."
},
"facets": {
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/Search-Documents"
},
"type": "array",
"items": {
"type": "string"
},
"description": "The list of facet expressions to apply to the search query. Each facet expression contains a field name, optionally followed by a comma-separated list of name:value pairs."
},
"filter": {
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/OData-Expression-Syntax-for-Azure-Search"
},
"type": "string",
"description": "The OData $filter expression to apply to the search query."
},
"highlight": {
"type": "string",
"description": "The comma-separated list of field names to use for hit highlights. Only searchable fields can be used for hit highlighting."
},
"highlightPostTag": {
"type": "string",
"description": "A string tag that is appended to hit highlights. Must be set with HighlightPreTag. Default is </em>."
},
"highlightPreTag": {
"type": "string",
"description": "A string tag that is prepended to hit highlights. Must be set with HighlightPostTag. Default is <em>."
},
"minimumCoverage": {
"type": "number",
"format": "double",
"description": "A number between 0 and 100 indicating the percentage of the index that must be covered by a search query in order for the query to be reported as a success. This parameter can be useful for ensuring search availability even for services with only one replica. The default is 100."
},
"orderby": {
"x-ms-client-name": "OrderBy",
"type": "string",
"description": "The comma-separated list of OData $orderby expressions by which to sort the results. Each expression can be either a field name or a call to the geo.distance() function. Each expression can be followed by asc to indicate ascending, and desc to indicate descending. The default is ascending order. Ties will be broken by the match scores of documents. If no OrderBy is specified, the default sort order is descending by document match score. There can be at most 32 Orderby clauses."
},
"queryType": {
"$ref": "#/definitions/QueryType",
"description": "Gets or sets a value that specifies the syntax of the search query. The default is 'simple'. Use 'full' if your query uses the Lucene query syntax."
},
"scoringParameters": {
"type": "array",
"items": {
"type": "string"
},
"description": "The list of parameter values to be used in scoring functions (for example, referencePointParameter) using the format name:value. For example, if the scoring profile defines a function with a parameter called 'mylocation' the parameter string would be \"mylocation:-122.2,44.8\"(without the quotes)."
},
"scoringProfile": {
"type": "string",
"description": "The name of a scoring profile to evaluate match scores for matching documents in order to sort the results."
},
"search": {
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/Simple-query-syntax-in-Azure-Search"
},
"type": "string",
"description": "A full-text search query expression; Use null or \"*\" to match all documents."
},
"searchFields": {
"type": "string",
"description": "The comma-separated list of field names to include in the full-text search."
},
"searchMode": {
"$ref": "#/definitions/SearchMode",
"description": "A value that specifies whether any or all of the search terms must be matched in order to count the document as a match."
},
"select": {
"type": "string",
"description": "The comma-separated list of fields to retrieve. If unspecified, all fields marked as retrievable in the schema are included."
},
"skip": {
"type": "integer",
"format": "int32",
"description": "The number of search results to skip. This value cannot be greater than 100,000. If you need to scan documents in sequence, but cannot use Skip due to this limitation, consider using OrderBy on a totally-ordered key and Filter with a range query instead."
},
"top": {
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/Search-Documents"
},
"type": "integer",
"format": "int32",
"description": "The number of search results to retrieve. This can be used in conjunction with Skip to implement client-side paging of search results. If results are truncated due to server-side paging, the response will include a continuation token that can be passed to ContinueSearch to retrieve the next page of results. See DocumentSearchResponse.ContinuationToken for more information."
}
},
"description": "Parameters for filtering, sorting, faceting, paging, and other search query behaviors."
},
"SuggestParametersPayload": {
"properties": {
"filter": {
"externalDocs": {
"url": "https://docs.microsoft.com/rest/api/searchservice/OData-Expression-Syntax-for-Azure-Search"
},
"type": "string",
"description": "The OData $filter expression to apply to the suggestions query."
},
"fuzzy": {
"type": "boolean",
"description": "A value indicating whether to use fuzzy matching for the suggestion query. Default is false. when set to true, the query will find suggestions even if there's a substituted or missing character in the search text. While this provides a better experience in some scenarios it comes at a performance cost as fuzzy suggestion searches are slower and consume more resources."
},
"highlightPostTag": {
"type": "string",
"description": "A string tag that is appended to hit highlights. Must be set with HighlightPreTag. If omitted, hit highlighting of suggestions is disabled."
},
"highlightPreTag": {
"type": "string",
"description": "A string tag that is prepended to hit highlights. Must be set with HighlightPostTag. If omitted, hit highlighting of suggestions is disabled."
},
"minimumCoverage": {
"type": "number",
"format": "double",
"description": "A number between 0 and 100 indicating the percentage of the index that must be covered by a suggestion query in order for the query to be reported as a success. This parameter can be useful for ensuring search availability even for services with only one replica. The default is 80."
},
"orderby": {
"x-ms-client-name": "OrderBy",
"type": "string",
"description": "The comma-separated list of OData $orderby expressions by which to sort the results. Each expression can be either a field name or a call to the geo.distance() function. Each expression can be followed by asc to indicate ascending, and desc to indicate descending. The default is ascending order. Ties will be broken by the match scores of documents. If no OrderBy is specified, the default sort order is descending by document match score. There can be at most 32 Orderby clauses."
},
"search": {
"type": "string",
"description": "The search text on which to base suggestions."
},
"searchFields": {
"type": "string",
"description": "The comma-separated list of field names to consider when querying for suggestions."
},
"select": {
"type": "string",
"description": "The comma-separated list of fields to retrieve. If unspecified, all fields marked as retrievable in the schema are included."
},
"suggesterName": {
"type": "string",
"description": "The name of the suggester as specified in the suggesters collection that's part of the index definition."
},
"top": {
"type": "integer",
"format": "int32",
"description": "The number of suggestions to retrieve. This must be a value between 1 and 100. The default is to 5."
}
},
"description": "Parameters for filtering, sorting, fuzzy matching, and other suggestions query behaviors."
}
},
"parameters": {
"ApiVersionParameter": {
"name": "api-version",
"in": "query",
"required": true,
"type": "string",
"description": "Client Api Version."
}
}
}
Loading

0 comments on commit 334f0d4

Please sign in to comment.