π§ GetFileWopiSrc (bootstrapper)ΒΆ
Warning
This operation should not be called by WOPI clients at this time. It is reserved for future use and subject to change.
-
POST/wopibootstrapperΒΆ This operation is equivalent to the π§ GetFileWopiSrc (ecosystem) operation.
Important
The request/response semantics for this operation differ slightly from its counterpart on the π§ Ecosystem endpoint since it is exposed on the π§ Bootstrapper endpoint and thus will use OAuth 2.0 access tokens for authorization instead of WOPI access tokens.
- Request Headers
X-WOPI-EcosystemOperation β The string
GET_WOPI_SRC_WITH_ACCESS_TOKEN. Required.X-WOPI-HostNativeFileName β A string representing the host-specific file identifier for a file.
Authorization β A string in the format
Bearer: <TOKEN>where<TOKEN>is a Base64-encoded OAuth 2.0 token. If this header is missing, or the token provided is invalid, the host must respond with a 401 Unauthorized response and include the WWW-Authenticate header as described in WWW-Authenticate response header format.
- Response Headers
WWW-Authenticate β A string value formatted as described in WWW-Authenticate response header format. This header should only be included when responding with a 401 Unauthorized.
- Status Codes
200 OK β Success
401 Unauthorized β Authorization failure; when responding with this status code, hosts must include a WWW-Authenticate response header with values as described in WWW-Authenticate response header format
404 Not Found β Resource not found/user unauthorized
500 Internal Server Error β Server error
ResponseΒΆ
The response to a GetFileWopiSrc call is JSON (as specified in RFC 4627) containing the following required properties:
- Bootstrap
The contents of this property should be the response to a Bootstrap operation.
- WopiSrcInfo
The contents of this property should be the response to a π§ GetFileWopiSrc (ecosystem) operation.
Sample responseΒΆ
{
"Bootstrap": {
"EcosystemUrl": "http://.../wopi*/ecosystem?access_token=<ecosystem_token>",
"UserId": "User ID",
"SignInName": "user@contoso.com",
"UserFriendlyName": "User Name"
},
"WopiSrcInfo": {
"Url": "http://.../wopi*/[containers|files]/<id>?access_token=<file|container_token>&access_token_ttl=<timestamp>"
}
}