mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-04-29 15:29:52 -05:00
Used expirationDateTime key for graph api (#9278)
This commit is contained in:
committed by
Ralf Haferkamp
parent
a0a3447a00
commit
5327f90712
+27
-11
@@ -7,26 +7,27 @@ This API client was generated by the [OpenAPI Generator](https://openapi-generat
|
||||
|
||||
- API version: v1.0.4
|
||||
- Package version: 1.0.0
|
||||
- Generator version: 7.6.0
|
||||
- Build package: org.openapitools.codegen.languages.GoClientCodegen
|
||||
|
||||
## Installation
|
||||
|
||||
Install the following dependencies:
|
||||
|
||||
```shell
|
||||
```sh
|
||||
go get github.com/stretchr/testify/assert
|
||||
go get golang.org/x/net/context
|
||||
```
|
||||
|
||||
Put the package under your project folder and add the following in import:
|
||||
|
||||
```golang
|
||||
```go
|
||||
import libregraph "github.com/owncloud/libre-graph-api-go"
|
||||
```
|
||||
|
||||
To use a proxy, set the environment variable `HTTP_PROXY`:
|
||||
|
||||
```golang
|
||||
```go
|
||||
os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")
|
||||
```
|
||||
|
||||
@@ -36,17 +37,17 @@ Default configuration comes with `Servers` field that contains server objects as
|
||||
|
||||
### Select Server Configuration
|
||||
|
||||
For using other server than the one defined on index 0 set context value `sw.ContextServerIndex` of type `int`.
|
||||
For using other server than the one defined on index 0 set context value `libregraph.ContextServerIndex` of type `int`.
|
||||
|
||||
```golang
|
||||
```go
|
||||
ctx := context.WithValue(context.Background(), libregraph.ContextServerIndex, 1)
|
||||
```
|
||||
|
||||
### Templated Server URL
|
||||
|
||||
Templated server URL is formatted using default variables from configuration or from context value `sw.ContextServerVariables` of type `map[string]string`.
|
||||
Templated server URL is formatted using default variables from configuration or from context value `libregraph.ContextServerVariables` of type `map[string]string`.
|
||||
|
||||
```golang
|
||||
```go
|
||||
ctx := context.WithValue(context.Background(), libregraph.ContextServerVariables, map[string]string{
|
||||
"basePath": "v2",
|
||||
})
|
||||
@@ -58,9 +59,9 @@ Note, enum values are always validated and all unused variables are silently ign
|
||||
|
||||
Each operation can use different server URL defined using `OperationServers` map in the `Configuration`.
|
||||
An operation is uniquely identified by `"{classname}Service.{nickname}"` string.
|
||||
Similar rules for overriding default operation server index and variables applies by using `sw.ContextOperationServerIndices` and `sw.ContextOperationServerVariables` context maps.
|
||||
Similar rules for overriding default operation server index and variables applies by using `libregraph.ContextOperationServerIndices` and `libregraph.ContextOperationServerVariables` context maps.
|
||||
|
||||
```golang
|
||||
```go
|
||||
ctx := context.WithValue(context.Background(), libregraph.ContextOperationServerIndices, map[string]int{
|
||||
"{classname}Service.{nickname}": 2,
|
||||
})
|
||||
@@ -196,6 +197,7 @@ Class | Method | HTTP request | Description
|
||||
- [DriveItemCreateLink](docs/DriveItemCreateLink.md)
|
||||
- [DriveItemInvite](docs/DriveItemInvite.md)
|
||||
- [DriveRecipient](docs/DriveRecipient.md)
|
||||
- [DriveUpdate](docs/DriveUpdate.md)
|
||||
- [EducationClass](docs/EducationClass.md)
|
||||
- [EducationSchool](docs/EducationSchool.md)
|
||||
- [EducationUser](docs/EducationUser.md)
|
||||
@@ -252,8 +254,22 @@ Authentication schemes defined for the API:
|
||||
|
||||
Example
|
||||
|
||||
```golang
|
||||
auth := context.WithValue(context.Background(), sw.ContextAccessToken, "BEARER_TOKEN_STRING")
|
||||
```go
|
||||
auth := context.WithValue(context.Background(), libregraph.ContextAccessToken, "BEARER_TOKEN_STRING")
|
||||
r, err := client.Service.Operation(auth, args)
|
||||
```
|
||||
|
||||
### basicAuth
|
||||
|
||||
- **Type**: HTTP basic authentication
|
||||
|
||||
Example
|
||||
|
||||
```go
|
||||
auth := context.WithValue(context.Background(), libregraph.ContextBasicAuth, libregraph.BasicAuth{
|
||||
UserName: "username",
|
||||
Password: "password",
|
||||
})
|
||||
r, err := client.Service.Operation(auth, args)
|
||||
```
|
||||
|
||||
|
||||
+9
-7
@@ -35,9 +35,9 @@ func (r ApiGetApplicationRequest) Execute() (*Application, *http.Response, error
|
||||
/*
|
||||
GetApplication Get application by id
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param applicationId key: id of application
|
||||
@return ApiGetApplicationRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param applicationId key: id of application
|
||||
@return ApiGetApplicationRequest
|
||||
*/
|
||||
func (a *ApplicationsApiService) GetApplication(ctx context.Context, applicationId string) ApiGetApplicationRequest {
|
||||
return ApiGetApplicationRequest{
|
||||
@@ -48,7 +48,8 @@ func (a *ApplicationsApiService) GetApplication(ctx context.Context, application
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Application
|
||||
//
|
||||
// @return Application
|
||||
func (a *ApplicationsApiService) GetApplicationExecute(r ApiGetApplicationRequest) (*Application, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -143,8 +144,8 @@ func (r ApiListApplicationsRequest) Execute() (*CollectionOfApplications, *http.
|
||||
/*
|
||||
ListApplications Get all applications
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListApplicationsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListApplicationsRequest
|
||||
*/
|
||||
func (a *ApplicationsApiService) ListApplications(ctx context.Context) ApiListApplicationsRequest {
|
||||
return ApiListApplicationsRequest{
|
||||
@@ -154,7 +155,8 @@ func (a *ApplicationsApiService) ListApplications(ctx context.Context) ApiListAp
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfApplications
|
||||
//
|
||||
// @return CollectionOfApplications
|
||||
func (a *ApplicationsApiService) ListApplicationsExecute(r ApiListApplicationsRequest) (*CollectionOfApplications, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+16
-17
@@ -42,11 +42,10 @@ Deleting items using this method moves the items to the recycle bin instead of p
|
||||
|
||||
Mounted shares in the share jail are unmounted. The `@client.synchronize` property of the `driveItem` in the [sharedWithMe](#/me.drive/ListSharedWithMe) endpoint will change to false.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiDeleteDriveItemRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiDeleteDriveItemRequest
|
||||
*/
|
||||
func (a *DriveItemApiService) DeleteDriveItem(ctx context.Context, driveId string, itemId string) ApiDeleteDriveItemRequest {
|
||||
return ApiDeleteDriveItemRequest{
|
||||
@@ -147,11 +146,10 @@ GetDriveItem Get a DriveItem.
|
||||
|
||||
Get a DriveItem by using its ID.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiGetDriveItemRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiGetDriveItemRequest
|
||||
*/
|
||||
func (a *DriveItemApiService) GetDriveItem(ctx context.Context, driveId string, itemId string) ApiGetDriveItemRequest {
|
||||
return ApiGetDriveItemRequest{
|
||||
@@ -163,7 +161,8 @@ func (a *DriveItemApiService) GetDriveItem(ctx context.Context, driveId string,
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return DriveItem
|
||||
//
|
||||
// @return DriveItem
|
||||
func (a *DriveItemApiService) GetDriveItemExecute(r ApiGetDriveItemRequest) (*DriveItem, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -277,11 +276,10 @@ Currently it supports updating the following properties:
|
||||
|
||||
* `@UI.Hidden` - Hides the item from the UI.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiUpdateDriveItemRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiUpdateDriveItemRequest
|
||||
*/
|
||||
func (a *DriveItemApiService) UpdateDriveItem(ctx context.Context, driveId string, itemId string) ApiUpdateDriveItemRequest {
|
||||
return ApiUpdateDriveItemRequest{
|
||||
@@ -293,7 +291,8 @@ func (a *DriveItemApiService) UpdateDriveItem(ctx context.Context, driveId strin
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return DriveItem
|
||||
//
|
||||
// @return DriveItem
|
||||
func (a *DriveItemApiService) UpdateDriveItemExecute(r ApiUpdateDriveItemRequest) (*DriveItem, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+26
-23
@@ -41,8 +41,8 @@ func (r ApiCreateDriveRequest) Execute() (*Drive, *http.Response, error) {
|
||||
/*
|
||||
CreateDrive Create a new drive of a specific type
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateDriveRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateDriveRequest
|
||||
*/
|
||||
func (a *DrivesApiService) CreateDrive(ctx context.Context) ApiCreateDriveRequest {
|
||||
return ApiCreateDriveRequest{
|
||||
@@ -52,7 +52,8 @@ func (a *DrivesApiService) CreateDrive(ctx context.Context) ApiCreateDriveReques
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Drive
|
||||
//
|
||||
// @return Drive
|
||||
func (a *DrivesApiService) CreateDriveExecute(r ApiCreateDriveRequest) (*Drive, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -159,9 +160,9 @@ func (r ApiDeleteDriveRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteDrive Delete a specific space
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiDeleteDriveRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiDeleteDriveRequest
|
||||
*/
|
||||
func (a *DrivesApiService) DeleteDrive(ctx context.Context, driveId string) ApiDeleteDriveRequest {
|
||||
return ApiDeleteDriveRequest{
|
||||
@@ -260,9 +261,9 @@ func (r ApiGetDriveRequest) Execute() (*Drive, *http.Response, error) {
|
||||
/*
|
||||
GetDrive Get drive by id
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiGetDriveRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiGetDriveRequest
|
||||
*/
|
||||
func (a *DrivesApiService) GetDrive(ctx context.Context, driveId string) ApiGetDriveRequest {
|
||||
return ApiGetDriveRequest{
|
||||
@@ -273,7 +274,8 @@ func (a *DrivesApiService) GetDrive(ctx context.Context, driveId string) ApiGetD
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Drive
|
||||
//
|
||||
// @return Drive
|
||||
func (a *DrivesApiService) GetDriveExecute(r ApiGetDriveRequest) (*Drive, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -357,15 +359,15 @@ func (a *DrivesApiService) GetDriveExecute(r ApiGetDriveRequest) (*Drive, *http.
|
||||
}
|
||||
|
||||
type ApiUpdateDriveRequest struct {
|
||||
ctx context.Context
|
||||
ApiService *DrivesApiService
|
||||
driveId string
|
||||
drive *Drive
|
||||
ctx context.Context
|
||||
ApiService *DrivesApiService
|
||||
driveId string
|
||||
driveUpdate *DriveUpdate
|
||||
}
|
||||
|
||||
// New space values
|
||||
func (r ApiUpdateDriveRequest) Drive(drive Drive) ApiUpdateDriveRequest {
|
||||
r.drive = &drive
|
||||
func (r ApiUpdateDriveRequest) DriveUpdate(driveUpdate DriveUpdate) ApiUpdateDriveRequest {
|
||||
r.driveUpdate = &driveUpdate
|
||||
return r
|
||||
}
|
||||
|
||||
@@ -376,9 +378,9 @@ func (r ApiUpdateDriveRequest) Execute() (*Drive, *http.Response, error) {
|
||||
/*
|
||||
UpdateDrive Update the drive
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiUpdateDriveRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiUpdateDriveRequest
|
||||
*/
|
||||
func (a *DrivesApiService) UpdateDrive(ctx context.Context, driveId string) ApiUpdateDriveRequest {
|
||||
return ApiUpdateDriveRequest{
|
||||
@@ -389,7 +391,8 @@ func (a *DrivesApiService) UpdateDrive(ctx context.Context, driveId string) ApiU
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Drive
|
||||
//
|
||||
// @return Drive
|
||||
func (a *DrivesApiService) UpdateDriveExecute(r ApiUpdateDriveRequest) (*Drive, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
@@ -409,8 +412,8 @@ func (a *DrivesApiService) UpdateDriveExecute(r ApiUpdateDriveRequest) (*Drive,
|
||||
localVarHeaderParams := make(map[string]string)
|
||||
localVarQueryParams := url.Values{}
|
||||
localVarFormParams := url.Values{}
|
||||
if r.drive == nil {
|
||||
return localVarReturnValue, nil, reportError("drive is required and must be specified")
|
||||
if r.driveUpdate == nil {
|
||||
return localVarReturnValue, nil, reportError("driveUpdate is required and must be specified")
|
||||
}
|
||||
|
||||
// to determine the Content-Type header
|
||||
@@ -431,7 +434,7 @@ func (a *DrivesApiService) UpdateDriveExecute(r ApiUpdateDriveRequest) (*Drive,
|
||||
localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept
|
||||
}
|
||||
// body params
|
||||
localVarPostBody = r.drive
|
||||
localVarPostBody = r.driveUpdate
|
||||
req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles)
|
||||
if err != nil {
|
||||
return localVarReturnValue, nil, err
|
||||
|
||||
+8
-6
@@ -47,8 +47,8 @@ func (r ApiListAllDrivesRequest) Execute() (*CollectionOfDrives1, *http.Response
|
||||
/*
|
||||
ListAllDrives Get all available drives
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListAllDrivesRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListAllDrivesRequest
|
||||
*/
|
||||
func (a *DrivesGetDrivesApiService) ListAllDrives(ctx context.Context) ApiListAllDrivesRequest {
|
||||
return ApiListAllDrivesRequest{
|
||||
@@ -58,7 +58,8 @@ func (a *DrivesGetDrivesApiService) ListAllDrives(ctx context.Context) ApiListAl
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDrives1
|
||||
//
|
||||
// @return CollectionOfDrives1
|
||||
func (a *DrivesGetDrivesApiService) ListAllDrivesExecute(r ApiListAllDrivesRequest) (*CollectionOfDrives1, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -172,8 +173,8 @@ func (r ApiListAllDrivesBetaRequest) Execute() (*CollectionOfDrives1, *http.Resp
|
||||
/*
|
||||
ListAllDrivesBeta Alias for '/v1.0/drives', the difference is that grantedtoV2 is used and roles contain unified roles instead of cs3 roles
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListAllDrivesBetaRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListAllDrivesBetaRequest
|
||||
*/
|
||||
func (a *DrivesGetDrivesApiService) ListAllDrivesBeta(ctx context.Context) ApiListAllDrivesBetaRequest {
|
||||
return ApiListAllDrivesBetaRequest{
|
||||
@@ -183,7 +184,8 @@ func (a *DrivesGetDrivesApiService) ListAllDrivesBeta(ctx context.Context) ApiLi
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDrives1
|
||||
//
|
||||
// @return CollectionOfDrives1
|
||||
func (a *DrivesGetDrivesApiService) ListAllDrivesBetaExecute(r ApiListAllDrivesBetaRequest) (*CollectionOfDrives1, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+44
-45
@@ -59,11 +59,10 @@ For now, The following values are allowed for the type parameter.
|
||||
| createOnly | File Drop | Creates an upload-only link to the folder driveItem. |
|
||||
| blocksDownload | Secure View | Creates a read-only link that blocks download to the driveItem. |
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiCreateLinkRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiCreateLinkRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) CreateLink(ctx context.Context, driveId string, itemId string) ApiCreateLinkRequest {
|
||||
return ApiCreateLinkRequest{
|
||||
@@ -75,7 +74,8 @@ func (a *DrivesPermissionsApiService) CreateLink(ctx context.Context, driveId st
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesPermissionsApiService) CreateLinkExecute(r ApiCreateLinkRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -180,12 +180,11 @@ Remove access to a DriveItem.
|
||||
|
||||
Only sharing permissions that are not inherited can be deleted. The `inheritedFrom` property must be `null`.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiDeletePermissionRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiDeletePermissionRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) DeletePermission(ctx context.Context, driveId string, itemId string, permId string) ApiDeletePermissionRequest {
|
||||
return ApiDeletePermissionRequest{
|
||||
@@ -289,12 +288,11 @@ GetPermission Get sharing permission for a file or folder
|
||||
|
||||
Return the effective sharing permission for a particular permission resource.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiGetPermissionRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiGetPermissionRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) GetPermission(ctx context.Context, driveId string, itemId string, permId string) ApiGetPermissionRequest {
|
||||
return ApiGetPermissionRequest{
|
||||
@@ -307,7 +305,8 @@ func (a *DrivesPermissionsApiService) GetPermission(ctx context.Context, driveId
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesPermissionsApiService) GetPermissionExecute(r ApiGetPermissionRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -421,11 +420,10 @@ The response will be a permission object with the grantedToV2 property containin
|
||||
## Roles property values
|
||||
For now, roles are only identified by a uuid. There are no hardcoded aliases like `read` or `write` because role actions can be completely customized.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiInviteRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiInviteRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) Invite(ctx context.Context, driveId string, itemId string) ApiInviteRequest {
|
||||
return ApiInviteRequest{
|
||||
@@ -437,7 +435,8 @@ func (a *DrivesPermissionsApiService) Invite(ctx context.Context, driveId string
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfPermissions
|
||||
//
|
||||
// @return CollectionOfPermissions
|
||||
func (a *DrivesPermissionsApiService) InviteExecute(r ApiInviteRequest) (*CollectionOfPermissions, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -558,11 +557,10 @@ All permission objects have an `id`. A permission representing
|
||||
* a link has the `link` facet filled with details.
|
||||
* a share has the `roles` property set and the `grantedToV2` property filled with the grant recipient details.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiListPermissionsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@return ApiListPermissionsRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) ListPermissions(ctx context.Context, driveId string, itemId string) ApiListPermissionsRequest {
|
||||
return ApiListPermissionsRequest{
|
||||
@@ -574,7 +572,8 @@ func (a *DrivesPermissionsApiService) ListPermissions(ctx context.Context, drive
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfPermissionsWithAllowedValues
|
||||
//
|
||||
// @return CollectionOfPermissionsWithAllowedValues
|
||||
func (a *DrivesPermissionsApiService) ListPermissionsExecute(r ApiListPermissionsRequest) (*CollectionOfPermissionsWithAllowedValues, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -684,12 +683,11 @@ Set the password of a sharing permission.
|
||||
|
||||
Only the `password` property can be modified this way.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiSetPermissionPasswordRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiSetPermissionPasswordRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) SetPermissionPassword(ctx context.Context, driveId string, itemId string, permId string) ApiSetPermissionPasswordRequest {
|
||||
return ApiSetPermissionPasswordRequest{
|
||||
@@ -702,7 +700,8 @@ func (a *DrivesPermissionsApiService) SetPermissionPassword(ctx context.Context,
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesPermissionsApiService) SetPermissionPasswordExecute(r ApiSetPermissionPasswordRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -818,12 +817,11 @@ Update the properties of a sharing permission by patching the permission resourc
|
||||
|
||||
Only the `roles`, `expirationDateTime` and `password` properties can be modified this way.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiUpdatePermissionRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param itemId key: id of item
|
||||
@param permId key: id of permission
|
||||
@return ApiUpdatePermissionRequest
|
||||
*/
|
||||
func (a *DrivesPermissionsApiService) UpdatePermission(ctx context.Context, driveId string, itemId string, permId string) ApiUpdatePermissionRequest {
|
||||
return ApiUpdatePermissionRequest{
|
||||
@@ -836,7 +834,8 @@ func (a *DrivesPermissionsApiService) UpdatePermission(ctx context.Context, driv
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesPermissionsApiService) UpdatePermissionExecute(r ApiUpdatePermissionRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+47
-47
@@ -44,10 +44,9 @@ CreateDriveItem Create a drive item
|
||||
|
||||
You can use the root childrens endpoint to mount a remoteItem in the share jail. The `@client.synchronize` property of the `driveItem` in the [sharedWithMe](#/me.drive/ListSharedWithMe) endpoint will change to true.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiCreateDriveItemRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiCreateDriveItemRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) CreateDriveItem(ctx context.Context, driveId string) ApiCreateDriveItemRequest {
|
||||
return ApiCreateDriveItemRequest{
|
||||
@@ -58,7 +57,8 @@ func (a *DrivesRootApiService) CreateDriveItem(ctx context.Context, driveId stri
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return DriveItem
|
||||
//
|
||||
// @return DriveItem
|
||||
func (a *DrivesRootApiService) CreateDriveItemExecute(r ApiCreateDriveItemRequest) (*DriveItem, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -179,10 +179,9 @@ For now, The following values are allowed for the type parameter.
|
||||
| createOnly | File Drop | Creates an upload-only link to the folder driveItem. |
|
||||
| blocksDownload | Secure View | Creates a read-only link that blocks download to the driveItem. |
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiCreateLinkSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiCreateLinkSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) CreateLinkSpaceRoot(ctx context.Context, driveId string) ApiCreateLinkSpaceRootRequest {
|
||||
return ApiCreateLinkSpaceRootRequest{
|
||||
@@ -193,7 +192,8 @@ func (a *DrivesRootApiService) CreateLinkSpaceRoot(ctx context.Context, driveId
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesRootApiService) CreateLinkSpaceRootExecute(r ApiCreateLinkSpaceRootRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -296,11 +296,10 @@ Remove access to the root item of a drive.
|
||||
|
||||
Only sharing permissions that are not inherited can be deleted. The `inheritedFrom` property must be `null`.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiDeletePermissionSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiDeletePermissionSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) DeletePermissionSpaceRoot(ctx context.Context, driveId string, permId string) ApiDeletePermissionSpaceRootRequest {
|
||||
return ApiDeletePermissionSpaceRootRequest{
|
||||
@@ -401,11 +400,10 @@ GetPermissionSpaceRoot Get a single sharing permission for the root item of a dr
|
||||
|
||||
Return the effective sharing permission for a particular permission resource.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiGetPermissionSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiGetPermissionSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) GetPermissionSpaceRoot(ctx context.Context, driveId string, permId string) ApiGetPermissionSpaceRootRequest {
|
||||
return ApiGetPermissionSpaceRootRequest{
|
||||
@@ -417,7 +415,8 @@ func (a *DrivesRootApiService) GetPermissionSpaceRoot(ctx context.Context, drive
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesRootApiService) GetPermissionSpaceRootExecute(r ApiGetPermissionSpaceRootRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -514,9 +513,9 @@ func (r ApiGetRootRequest) Execute() (*DriveItem, *http.Response, error) {
|
||||
/*
|
||||
GetRoot Get root from arbitrary space
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiGetRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiGetRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) GetRoot(ctx context.Context, driveId string) ApiGetRootRequest {
|
||||
return ApiGetRootRequest{
|
||||
@@ -527,7 +526,8 @@ func (a *DrivesRootApiService) GetRoot(ctx context.Context, driveId string) ApiG
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return DriveItem
|
||||
//
|
||||
// @return DriveItem
|
||||
func (a *DrivesRootApiService) GetRootExecute(r ApiGetRootRequest) (*DriveItem, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -638,10 +638,9 @@ The response will be a permission object with the grantedToV2 property containin
|
||||
## Roles property values
|
||||
For now, roles are only identified by a uuid. There are no hardcoded aliases like `read` or `write` because role actions can be completely customized.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiInviteSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiInviteSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) InviteSpaceRoot(ctx context.Context, driveId string) ApiInviteSpaceRootRequest {
|
||||
return ApiInviteSpaceRootRequest{
|
||||
@@ -652,7 +651,8 @@ func (a *DrivesRootApiService) InviteSpaceRoot(ctx context.Context, driveId stri
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfPermissions
|
||||
//
|
||||
// @return CollectionOfPermissions
|
||||
func (a *DrivesRootApiService) InviteSpaceRootExecute(r ApiInviteSpaceRootRequest) (*CollectionOfPermissions, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -771,10 +771,9 @@ All permission objects have an `id`. A permission representing
|
||||
* a link has the `link` facet filled with details.
|
||||
* a share has the `roles` property set and the `grantedToV2` property filled with the grant recipient details.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiListPermissionsSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@return ApiListPermissionsSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) ListPermissionsSpaceRoot(ctx context.Context, driveId string) ApiListPermissionsSpaceRootRequest {
|
||||
return ApiListPermissionsSpaceRootRequest{
|
||||
@@ -785,7 +784,8 @@ func (a *DrivesRootApiService) ListPermissionsSpaceRoot(ctx context.Context, dri
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfPermissionsWithAllowedValues
|
||||
//
|
||||
// @return CollectionOfPermissionsWithAllowedValues
|
||||
func (a *DrivesRootApiService) ListPermissionsSpaceRootExecute(r ApiListPermissionsSpaceRootRequest) (*CollectionOfPermissionsWithAllowedValues, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -893,11 +893,10 @@ Set the password of a sharing permission.
|
||||
|
||||
Only the `password` property can be modified this way.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiSetPermissionPasswordSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiSetPermissionPasswordSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) SetPermissionPasswordSpaceRoot(ctx context.Context, driveId string, permId string) ApiSetPermissionPasswordSpaceRootRequest {
|
||||
return ApiSetPermissionPasswordSpaceRootRequest{
|
||||
@@ -909,7 +908,8 @@ func (a *DrivesRootApiService) SetPermissionPasswordSpaceRoot(ctx context.Contex
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesRootApiService) SetPermissionPasswordSpaceRootExecute(r ApiSetPermissionPasswordSpaceRootRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -1023,11 +1023,10 @@ Update the properties of a sharing permission by patching the permission resourc
|
||||
|
||||
Only the `roles`, `expirationDateTime` and `password` properties can be modified this way.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiUpdatePermissionSpaceRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param driveId key: id of drive
|
||||
@param permId key: id of permission
|
||||
@return ApiUpdatePermissionSpaceRootRequest
|
||||
*/
|
||||
func (a *DrivesRootApiService) UpdatePermissionSpaceRoot(ctx context.Context, driveId string, permId string) ApiUpdatePermissionSpaceRootRequest {
|
||||
return ApiUpdatePermissionSpaceRootRequest{
|
||||
@@ -1039,7 +1038,8 @@ func (a *DrivesRootApiService) UpdatePermissionSpaceRoot(ctx context.Context, dr
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Permission
|
||||
//
|
||||
// @return Permission
|
||||
func (a *DrivesRootApiService) UpdatePermissionSpaceRootExecute(r ApiUpdatePermissionSpaceRootRequest) (*Permission, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+33
-28
@@ -42,9 +42,9 @@ func (r ApiAddUserToClassRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AddUserToClass Assign a user to a class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiAddUserToClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiAddUserToClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) AddUserToClass(ctx context.Context, classId string) ApiAddUserToClassRequest {
|
||||
return ApiAddUserToClassRequest{
|
||||
@@ -151,8 +151,8 @@ func (r ApiCreateClassRequest) Execute() (*EducationClass, *http.Response, error
|
||||
/*
|
||||
CreateClass Add new education class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) CreateClass(ctx context.Context) ApiCreateClassRequest {
|
||||
return ApiCreateClassRequest{
|
||||
@@ -162,7 +162,8 @@ func (a *EducationClassApiService) CreateClass(ctx context.Context) ApiCreateCla
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationClass
|
||||
//
|
||||
// @return EducationClass
|
||||
func (a *EducationClassApiService) CreateClassExecute(r ApiCreateClassRequest) (*EducationClass, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -262,9 +263,9 @@ func (r ApiDeleteClassRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteClass Delete education class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiDeleteClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiDeleteClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) DeleteClass(ctx context.Context, classId string) ApiDeleteClassRequest {
|
||||
return ApiDeleteClassRequest{
|
||||
@@ -361,10 +362,10 @@ func (r ApiDeleteUserFromClassRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteUserFromClass Unassign user from a class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@param userId key: id or username of the user to unassign from class
|
||||
@return ApiDeleteUserFromClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@param userId key: id or username of the user to unassign from class
|
||||
@return ApiDeleteUserFromClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) DeleteUserFromClass(ctx context.Context, classId string, userId string) ApiDeleteUserFromClassRequest {
|
||||
return ApiDeleteUserFromClassRequest{
|
||||
@@ -462,9 +463,9 @@ func (r ApiGetClassRequest) Execute() (*EducationClass, *http.Response, error) {
|
||||
/*
|
||||
GetClass Get class by key
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiGetClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiGetClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) GetClass(ctx context.Context, classId string) ApiGetClassRequest {
|
||||
return ApiGetClassRequest{
|
||||
@@ -475,7 +476,8 @@ func (a *EducationClassApiService) GetClass(ctx context.Context, classId string)
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationClass
|
||||
//
|
||||
// @return EducationClass
|
||||
func (a *EducationClassApiService) GetClassExecute(r ApiGetClassRequest) (*EducationClass, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -571,9 +573,9 @@ func (r ApiListClassMembersRequest) Execute() (*CollectionOfEducationUser, *http
|
||||
/*
|
||||
ListClassMembers Get the educationClass resources owned by an educationSchool
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiListClassMembersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiListClassMembersRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) ListClassMembers(ctx context.Context, classId string) ApiListClassMembersRequest {
|
||||
return ApiListClassMembersRequest{
|
||||
@@ -584,7 +586,8 @@ func (a *EducationClassApiService) ListClassMembers(ctx context.Context, classId
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfEducationUser
|
||||
//
|
||||
// @return CollectionOfEducationUser
|
||||
func (a *EducationClassApiService) ListClassMembersExecute(r ApiListClassMembersRequest) (*CollectionOfEducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -679,8 +682,8 @@ func (r ApiListClassesRequest) Execute() (*CollectionOfClass, *http.Response, er
|
||||
/*
|
||||
ListClasses list education classes
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListClassesRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListClassesRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) ListClasses(ctx context.Context) ApiListClassesRequest {
|
||||
return ApiListClassesRequest{
|
||||
@@ -690,7 +693,8 @@ func (a *EducationClassApiService) ListClasses(ctx context.Context) ApiListClass
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfClass
|
||||
//
|
||||
// @return CollectionOfClass
|
||||
func (a *EducationClassApiService) ListClassesExecute(r ApiListClassesRequest) (*CollectionOfClass, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -792,9 +796,9 @@ func (r ApiUpdateClassRequest) Execute() (*EducationClass, *http.Response, error
|
||||
/*
|
||||
UpdateClass Update properties of a education class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiUpdateClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiUpdateClassRequest
|
||||
*/
|
||||
func (a *EducationClassApiService) UpdateClass(ctx context.Context, classId string) ApiUpdateClassRequest {
|
||||
return ApiUpdateClassRequest{
|
||||
@@ -805,7 +809,8 @@ func (a *EducationClassApiService) UpdateClass(ctx context.Context, classId stri
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationClass
|
||||
//
|
||||
// @return EducationClass
|
||||
func (a *EducationClassApiService) UpdateClassExecute(r ApiUpdateClassRequest) (*EducationClass, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+12
-11
@@ -42,9 +42,9 @@ func (r ApiAddTeacherToClassRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AddTeacherToClass Assign a teacher to a class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiAddTeacherToClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiAddTeacherToClassRequest
|
||||
*/
|
||||
func (a *EducationClassTeachersApiService) AddTeacherToClass(ctx context.Context, classId string) ApiAddTeacherToClassRequest {
|
||||
return ApiAddTeacherToClassRequest{
|
||||
@@ -146,10 +146,10 @@ func (r ApiDeleteTeacherFromClassRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteTeacherFromClass Unassign user as teacher of a class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@param userId key: id or username of the user to unassign as teacher
|
||||
@return ApiDeleteTeacherFromClassRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@param userId key: id or username of the user to unassign as teacher
|
||||
@return ApiDeleteTeacherFromClassRequest
|
||||
*/
|
||||
func (a *EducationClassTeachersApiService) DeleteTeacherFromClass(ctx context.Context, classId string, userId string) ApiDeleteTeacherFromClassRequest {
|
||||
return ApiDeleteTeacherFromClassRequest{
|
||||
@@ -247,9 +247,9 @@ func (r ApiGetTeachersRequest) Execute() (*CollectionOfEducationUser, *http.Resp
|
||||
/*
|
||||
GetTeachers Get the teachers for a class
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiGetTeachersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param classId key: id or externalId of class
|
||||
@return ApiGetTeachersRequest
|
||||
*/
|
||||
func (a *EducationClassTeachersApiService) GetTeachers(ctx context.Context, classId string) ApiGetTeachersRequest {
|
||||
return ApiGetTeachersRequest{
|
||||
@@ -260,7 +260,8 @@ func (a *EducationClassTeachersApiService) GetTeachers(ctx context.Context, clas
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfEducationUser
|
||||
//
|
||||
// @return CollectionOfEducationUser
|
||||
func (a *EducationClassTeachersApiService) GetTeachersExecute(r ApiGetTeachersRequest) (*CollectionOfEducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+45
-39
@@ -42,9 +42,9 @@ func (r ApiAddClassToSchoolRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AddClassToSchool Assign a class to a school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiAddClassToSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiAddClassToSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) AddClassToSchool(ctx context.Context, schoolId string) ApiAddClassToSchoolRequest {
|
||||
return ApiAddClassToSchoolRequest{
|
||||
@@ -152,9 +152,9 @@ func (r ApiAddUserToSchoolRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AddUserToSchool Assign a user to a school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiAddUserToSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiAddUserToSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) AddUserToSchool(ctx context.Context, schoolId string) ApiAddUserToSchoolRequest {
|
||||
return ApiAddUserToSchoolRequest{
|
||||
@@ -261,8 +261,8 @@ func (r ApiCreateSchoolRequest) Execute() (*EducationSchool, *http.Response, err
|
||||
/*
|
||||
CreateSchool Add new school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) CreateSchool(ctx context.Context) ApiCreateSchoolRequest {
|
||||
return ApiCreateSchoolRequest{
|
||||
@@ -272,7 +272,8 @@ func (a *EducationSchoolApiService) CreateSchool(ctx context.Context) ApiCreateS
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationSchool
|
||||
//
|
||||
// @return EducationSchool
|
||||
func (a *EducationSchoolApiService) CreateSchoolExecute(r ApiCreateSchoolRequest) (*EducationSchool, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -373,10 +374,10 @@ func (r ApiDeleteClassFromSchoolRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteClassFromSchool Unassign class from a school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@param classId key: id or externalId of the class to unassign from school
|
||||
@return ApiDeleteClassFromSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@param classId key: id or externalId of the class to unassign from school
|
||||
@return ApiDeleteClassFromSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) DeleteClassFromSchool(ctx context.Context, schoolId string, classId string) ApiDeleteClassFromSchoolRequest {
|
||||
return ApiDeleteClassFromSchoolRequest{
|
||||
@@ -476,9 +477,9 @@ DeleteSchool Delete school
|
||||
|
||||
Deletes a school. A school can only be delete if it has the terminationDate property set. And if that termination Date is in the past.
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiDeleteSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiDeleteSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) DeleteSchool(ctx context.Context, schoolId string) ApiDeleteSchoolRequest {
|
||||
return ApiDeleteSchoolRequest{
|
||||
@@ -575,10 +576,10 @@ func (r ApiDeleteUserFromSchoolRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteUserFromSchool Unassign user from a school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@param userId key: id or username of the user to unassign from school
|
||||
@return ApiDeleteUserFromSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@param userId key: id or username of the user to unassign from school
|
||||
@return ApiDeleteUserFromSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) DeleteUserFromSchool(ctx context.Context, schoolId string, userId string) ApiDeleteUserFromSchoolRequest {
|
||||
return ApiDeleteUserFromSchoolRequest{
|
||||
@@ -676,9 +677,9 @@ func (r ApiGetSchoolRequest) Execute() (*EducationSchool, *http.Response, error)
|
||||
/*
|
||||
GetSchool Get the properties of a specific school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiGetSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiGetSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) GetSchool(ctx context.Context, schoolId string) ApiGetSchoolRequest {
|
||||
return ApiGetSchoolRequest{
|
||||
@@ -689,7 +690,8 @@ func (a *EducationSchoolApiService) GetSchool(ctx context.Context, schoolId stri
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationSchool
|
||||
//
|
||||
// @return EducationSchool
|
||||
func (a *EducationSchoolApiService) GetSchoolExecute(r ApiGetSchoolRequest) (*EducationSchool, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -785,9 +787,9 @@ func (r ApiListSchoolClassesRequest) Execute() (*CollectionOfEducationClass, *ht
|
||||
/*
|
||||
ListSchoolClasses Get the educationClass resources owned by an educationSchool
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiListSchoolClassesRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiListSchoolClassesRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) ListSchoolClasses(ctx context.Context, schoolId string) ApiListSchoolClassesRequest {
|
||||
return ApiListSchoolClassesRequest{
|
||||
@@ -798,7 +800,8 @@ func (a *EducationSchoolApiService) ListSchoolClasses(ctx context.Context, schoo
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfEducationClass
|
||||
//
|
||||
// @return CollectionOfEducationClass
|
||||
func (a *EducationSchoolApiService) ListSchoolClassesExecute(r ApiListSchoolClassesRequest) (*CollectionOfEducationClass, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -894,9 +897,9 @@ func (r ApiListSchoolUsersRequest) Execute() (*CollectionOfEducationUser, *http.
|
||||
/*
|
||||
ListSchoolUsers Get the educationUser resources associated with an educationSchool
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiListSchoolUsersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiListSchoolUsersRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) ListSchoolUsers(ctx context.Context, schoolId string) ApiListSchoolUsersRequest {
|
||||
return ApiListSchoolUsersRequest{
|
||||
@@ -907,7 +910,8 @@ func (a *EducationSchoolApiService) ListSchoolUsers(ctx context.Context, schoolI
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfEducationUser
|
||||
//
|
||||
// @return CollectionOfEducationUser
|
||||
func (a *EducationSchoolApiService) ListSchoolUsersExecute(r ApiListSchoolUsersRequest) (*CollectionOfEducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -1002,8 +1006,8 @@ func (r ApiListSchoolsRequest) Execute() (*CollectionOfSchools, *http.Response,
|
||||
/*
|
||||
ListSchools Get a list of schools and their properties
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSchoolsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSchoolsRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) ListSchools(ctx context.Context) ApiListSchoolsRequest {
|
||||
return ApiListSchoolsRequest{
|
||||
@@ -1013,7 +1017,8 @@ func (a *EducationSchoolApiService) ListSchools(ctx context.Context) ApiListScho
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfSchools
|
||||
//
|
||||
// @return CollectionOfSchools
|
||||
func (a *EducationSchoolApiService) ListSchoolsExecute(r ApiListSchoolsRequest) (*CollectionOfSchools, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -1115,9 +1120,9 @@ func (r ApiUpdateSchoolRequest) Execute() (*EducationSchool, *http.Response, err
|
||||
/*
|
||||
UpdateSchool Update properties of a school
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiUpdateSchoolRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param schoolId key: id or schoolNumber of school
|
||||
@return ApiUpdateSchoolRequest
|
||||
*/
|
||||
func (a *EducationSchoolApiService) UpdateSchool(ctx context.Context, schoolId string) ApiUpdateSchoolRequest {
|
||||
return ApiUpdateSchoolRequest{
|
||||
@@ -1128,7 +1133,8 @@ func (a *EducationSchoolApiService) UpdateSchool(ctx context.Context, schoolId s
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationSchool
|
||||
//
|
||||
// @return EducationSchool
|
||||
func (a *EducationSchoolApiService) UpdateSchoolExecute(r ApiUpdateSchoolRequest) (*EducationSchool, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+21
-17
@@ -41,8 +41,8 @@ func (r ApiCreateEducationUserRequest) Execute() (*EducationUser, *http.Response
|
||||
/*
|
||||
CreateEducationUser Add new education user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateEducationUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateEducationUserRequest
|
||||
*/
|
||||
func (a *EducationUserApiService) CreateEducationUser(ctx context.Context) ApiCreateEducationUserRequest {
|
||||
return ApiCreateEducationUserRequest{
|
||||
@@ -52,7 +52,8 @@ func (a *EducationUserApiService) CreateEducationUser(ctx context.Context) ApiCr
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationUser
|
||||
//
|
||||
// @return EducationUser
|
||||
func (a *EducationUserApiService) CreateEducationUserExecute(r ApiCreateEducationUserRequest) (*EducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -152,9 +153,9 @@ func (r ApiDeleteEducationUserRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteEducationUser Delete educationUser
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiDeleteEducationUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiDeleteEducationUserRequest
|
||||
*/
|
||||
func (a *EducationUserApiService) DeleteEducationUser(ctx context.Context, userId string) ApiDeleteEducationUserRequest {
|
||||
return ApiDeleteEducationUserRequest{
|
||||
@@ -257,9 +258,9 @@ func (r ApiGetEducationUserRequest) Execute() (*EducationUser, *http.Response, e
|
||||
/*
|
||||
GetEducationUser Get properties of educationUser
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiGetEducationUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiGetEducationUserRequest
|
||||
*/
|
||||
func (a *EducationUserApiService) GetEducationUser(ctx context.Context, userId string) ApiGetEducationUserRequest {
|
||||
return ApiGetEducationUserRequest{
|
||||
@@ -270,7 +271,8 @@ func (a *EducationUserApiService) GetEducationUser(ctx context.Context, userId s
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationUser
|
||||
//
|
||||
// @return EducationUser
|
||||
func (a *EducationUserApiService) GetEducationUserExecute(r ApiGetEducationUserRequest) (*EducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -382,8 +384,8 @@ func (r ApiListEducationUsersRequest) Execute() (*CollectionOfEducationUser, *ht
|
||||
/*
|
||||
ListEducationUsers Get entities from education users
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListEducationUsersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListEducationUsersRequest
|
||||
*/
|
||||
func (a *EducationUserApiService) ListEducationUsers(ctx context.Context) ApiListEducationUsersRequest {
|
||||
return ApiListEducationUsersRequest{
|
||||
@@ -393,7 +395,8 @@ func (a *EducationUserApiService) ListEducationUsers(ctx context.Context) ApiLis
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfEducationUser
|
||||
//
|
||||
// @return CollectionOfEducationUser
|
||||
func (a *EducationUserApiService) ListEducationUsersExecute(r ApiListEducationUsersRequest) (*CollectionOfEducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -501,9 +504,9 @@ func (r ApiUpdateEducationUserRequest) Execute() (*EducationUser, *http.Response
|
||||
/*
|
||||
UpdateEducationUser Update properties of educationUser
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiUpdateEducationUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or username of user
|
||||
@return ApiUpdateEducationUserRequest
|
||||
*/
|
||||
func (a *EducationUserApiService) UpdateEducationUser(ctx context.Context, userId string) ApiUpdateEducationUserRequest {
|
||||
return ApiUpdateEducationUserRequest{
|
||||
@@ -514,7 +517,8 @@ func (a *EducationUserApiService) UpdateEducationUser(ctx context.Context, userI
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return EducationUser
|
||||
//
|
||||
// @return EducationUser
|
||||
func (a *EducationUserApiService) UpdateEducationUserExecute(r ApiUpdateEducationUserRequest) (*EducationUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+23
-21
@@ -42,9 +42,9 @@ func (r ApiAddMemberRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AddMember Add a member to a group
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiAddMemberRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiAddMemberRequest
|
||||
*/
|
||||
func (a *GroupApiService) AddMember(ctx context.Context, groupId string) ApiAddMemberRequest {
|
||||
return ApiAddMemberRequest{
|
||||
@@ -152,9 +152,9 @@ func (r ApiDeleteGroupRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteGroup Delete entity from groups
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiDeleteGroupRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiDeleteGroupRequest
|
||||
*/
|
||||
func (a *GroupApiService) DeleteGroup(ctx context.Context, groupId string) ApiDeleteGroupRequest {
|
||||
return ApiDeleteGroupRequest{
|
||||
@@ -261,10 +261,10 @@ func (r ApiDeleteMemberRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteMember Delete member from a group
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@param directoryObjectId key: id of group member to remove
|
||||
@return ApiDeleteMemberRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@param directoryObjectId key: id of group member to remove
|
||||
@return ApiDeleteMemberRequest
|
||||
*/
|
||||
func (a *GroupApiService) DeleteMember(ctx context.Context, groupId string, directoryObjectId string) ApiDeleteMemberRequest {
|
||||
return ApiDeleteMemberRequest{
|
||||
@@ -379,9 +379,9 @@ func (r ApiGetGroupRequest) Execute() (*Group, *http.Response, error) {
|
||||
/*
|
||||
GetGroup Get entity from groups by key
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id or name of group
|
||||
@return ApiGetGroupRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id or name of group
|
||||
@return ApiGetGroupRequest
|
||||
*/
|
||||
func (a *GroupApiService) GetGroup(ctx context.Context, groupId string) ApiGetGroupRequest {
|
||||
return ApiGetGroupRequest{
|
||||
@@ -392,7 +392,8 @@ func (a *GroupApiService) GetGroup(ctx context.Context, groupId string) ApiGetGr
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Group
|
||||
//
|
||||
// @return Group
|
||||
func (a *GroupApiService) GetGroupExecute(r ApiGetGroupRequest) (*Group, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -494,9 +495,9 @@ func (r ApiListMembersRequest) Execute() (*CollectionOfUsers, *http.Response, er
|
||||
/*
|
||||
ListMembers Get a list of the group's direct members
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id or name of group
|
||||
@return ApiListMembersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id or name of group
|
||||
@return ApiListMembersRequest
|
||||
*/
|
||||
func (a *GroupApiService) ListMembers(ctx context.Context, groupId string) ApiListMembersRequest {
|
||||
return ApiListMembersRequest{
|
||||
@@ -507,7 +508,8 @@ func (a *GroupApiService) ListMembers(ctx context.Context, groupId string) ApiLi
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfUsers
|
||||
//
|
||||
// @return CollectionOfUsers
|
||||
func (a *GroupApiService) ListMembersExecute(r ApiListMembersRequest) (*CollectionOfUsers, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -610,9 +612,9 @@ func (r ApiUpdateGroupRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
UpdateGroup Update entity in groups
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiUpdateGroupRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param groupId key: id of group
|
||||
@return ApiUpdateGroupRequest
|
||||
*/
|
||||
func (a *GroupApiService) UpdateGroup(ctx context.Context, groupId string) ApiUpdateGroupRequest {
|
||||
return ApiUpdateGroupRequest{
|
||||
|
||||
+8
-6
@@ -40,8 +40,8 @@ func (r ApiCreateGroupRequest) Execute() (*Group, *http.Response, error) {
|
||||
/*
|
||||
CreateGroup Add new entity to groups
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateGroupRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateGroupRequest
|
||||
*/
|
||||
func (a *GroupsApiService) CreateGroup(ctx context.Context) ApiCreateGroupRequest {
|
||||
return ApiCreateGroupRequest{
|
||||
@@ -51,7 +51,8 @@ func (a *GroupsApiService) CreateGroup(ctx context.Context) ApiCreateGroupReques
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Group
|
||||
//
|
||||
// @return Group
|
||||
func (a *GroupsApiService) CreateGroupExecute(r ApiCreateGroupRequest) (*Group, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -178,8 +179,8 @@ func (r ApiListGroupsRequest) Execute() (*CollectionOfGroup, *http.Response, err
|
||||
/*
|
||||
ListGroups Get entities from groups
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListGroupsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListGroupsRequest
|
||||
*/
|
||||
func (a *GroupsApiService) ListGroups(ctx context.Context) ApiListGroupsRequest {
|
||||
return ApiListGroupsRequest{
|
||||
@@ -189,7 +190,8 @@ func (a *GroupsApiService) ListGroups(ctx context.Context) ApiListGroupsRequest
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfGroup
|
||||
//
|
||||
// @return CollectionOfGroup
|
||||
func (a *GroupsApiService) ListGroupsExecute(r ApiListGroupsRequest) (*CollectionOfGroup, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+2
-2
@@ -40,8 +40,8 @@ func (r ApiChangeOwnPasswordRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
ChangeOwnPassword Chanage your own password
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiChangeOwnPasswordRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiChangeOwnPasswordRequest
|
||||
*/
|
||||
func (a *MeChangepasswordApiService) ChangeOwnPassword(ctx context.Context) ApiChangeOwnPasswordRequest {
|
||||
return ApiChangeOwnPasswordRequest{
|
||||
|
||||
+12
-11
@@ -33,8 +33,8 @@ func (r ApiGetHomeRequest) Execute() (*Drive, *http.Response, error) {
|
||||
/*
|
||||
GetHome Get personal space for user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetHomeRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetHomeRequest
|
||||
*/
|
||||
func (a *MeDriveApiService) GetHome(ctx context.Context) ApiGetHomeRequest {
|
||||
return ApiGetHomeRequest{
|
||||
@@ -44,7 +44,8 @@ func (a *MeDriveApiService) GetHome(ctx context.Context) ApiGetHomeRequest {
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return Drive
|
||||
//
|
||||
// @return Drive
|
||||
func (a *MeDriveApiService) GetHomeExecute(r ApiGetHomeRequest) (*Drive, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -140,9 +141,8 @@ ListSharedByMe Get a list of driveItem objects shared by the current user.
|
||||
|
||||
The `driveItems` returned from the `sharedByMe` method always include the `permissions` relation that indicates they are shared items.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSharedByMeRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSharedByMeRequest
|
||||
*/
|
||||
func (a *MeDriveApiService) ListSharedByMe(ctx context.Context) ApiListSharedByMeRequest {
|
||||
return ApiListSharedByMeRequest{
|
||||
@@ -152,7 +152,8 @@ func (a *MeDriveApiService) ListSharedByMe(ctx context.Context) ApiListSharedByM
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDriveItems1
|
||||
//
|
||||
// @return CollectionOfDriveItems1
|
||||
func (a *MeDriveApiService) ListSharedByMeExecute(r ApiListSharedByMeRequest) (*CollectionOfDriveItems1, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -248,9 +249,8 @@ ListSharedWithMe Get a list of driveItem objects shared with the owner of a driv
|
||||
|
||||
The `driveItems` returned from the `sharedWithMe` method always include the `remoteItem` facet that indicates they are items from a different drive.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSharedWithMeRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListSharedWithMeRequest
|
||||
*/
|
||||
func (a *MeDriveApiService) ListSharedWithMe(ctx context.Context) ApiListSharedWithMeRequest {
|
||||
return ApiListSharedWithMeRequest{
|
||||
@@ -260,7 +260,8 @@ func (a *MeDriveApiService) ListSharedWithMe(ctx context.Context) ApiListSharedW
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDriveItems1
|
||||
//
|
||||
// @return CollectionOfDriveItems1
|
||||
func (a *MeDriveApiService) ListSharedWithMeExecute(r ApiListSharedWithMeRequest) (*CollectionOfDriveItems1, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+4
-3
@@ -33,8 +33,8 @@ func (r ApiHomeGetRootRequest) Execute() (*DriveItem, *http.Response, error) {
|
||||
/*
|
||||
HomeGetRoot Get root from personal space
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiHomeGetRootRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiHomeGetRootRequest
|
||||
*/
|
||||
func (a *MeDriveRootApiService) HomeGetRoot(ctx context.Context) ApiHomeGetRootRequest {
|
||||
return ApiHomeGetRootRequest{
|
||||
@@ -44,7 +44,8 @@ func (a *MeDriveRootApiService) HomeGetRoot(ctx context.Context) ApiHomeGetRootR
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return DriveItem
|
||||
//
|
||||
// @return DriveItem
|
||||
func (a *MeDriveRootApiService) HomeGetRootExecute(r ApiHomeGetRootRequest) (*DriveItem, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+4
-3
@@ -33,8 +33,8 @@ func (r ApiHomeGetChildrenRequest) Execute() (*CollectionOfDriveItems, *http.Res
|
||||
/*
|
||||
HomeGetChildren Get children from drive
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiHomeGetChildrenRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiHomeGetChildrenRequest
|
||||
*/
|
||||
func (a *MeDriveRootChildrenApiService) HomeGetChildren(ctx context.Context) ApiHomeGetChildrenRequest {
|
||||
return ApiHomeGetChildrenRequest{
|
||||
@@ -44,7 +44,8 @@ func (a *MeDriveRootChildrenApiService) HomeGetChildren(ctx context.Context) Api
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDriveItems
|
||||
//
|
||||
// @return CollectionOfDriveItems
|
||||
func (a *MeDriveRootChildrenApiService) HomeGetChildrenExecute(r ApiHomeGetChildrenRequest) (*CollectionOfDriveItems, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+8
-6
@@ -47,8 +47,8 @@ func (r ApiListMyDrivesRequest) Execute() (*CollectionOfDrives, *http.Response,
|
||||
/*
|
||||
ListMyDrives Get all drives where the current user is a regular member of
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListMyDrivesRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListMyDrivesRequest
|
||||
*/
|
||||
func (a *MeDrivesApiService) ListMyDrives(ctx context.Context) ApiListMyDrivesRequest {
|
||||
return ApiListMyDrivesRequest{
|
||||
@@ -58,7 +58,8 @@ func (a *MeDrivesApiService) ListMyDrives(ctx context.Context) ApiListMyDrivesRe
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDrives
|
||||
//
|
||||
// @return CollectionOfDrives
|
||||
func (a *MeDrivesApiService) ListMyDrivesExecute(r ApiListMyDrivesRequest) (*CollectionOfDrives, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -172,8 +173,8 @@ func (r ApiListMyDrivesBetaRequest) Execute() (*CollectionOfDrives, *http.Respon
|
||||
/*
|
||||
ListMyDrivesBeta Alias for '/v1.0/drives', the difference is that grantedtoV2 is used and roles contain unified roles instead of cs3 roles
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListMyDrivesBetaRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListMyDrivesBetaRequest
|
||||
*/
|
||||
func (a *MeDrivesApiService) ListMyDrivesBeta(ctx context.Context) ApiListMyDrivesBetaRequest {
|
||||
return ApiListMyDrivesBetaRequest{
|
||||
@@ -183,7 +184,8 @@ func (a *MeDrivesApiService) ListMyDrivesBeta(ctx context.Context) ApiListMyDriv
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfDrives
|
||||
//
|
||||
// @return CollectionOfDrives
|
||||
func (a *MeDrivesApiService) ListMyDrivesBetaExecute(r ApiListMyDrivesBetaRequest) (*CollectionOfDrives, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+8
-6
@@ -40,8 +40,8 @@ func (r ApiGetOwnUserRequest) Execute() (*User, *http.Response, error) {
|
||||
/*
|
||||
GetOwnUser Get current user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetOwnUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetOwnUserRequest
|
||||
*/
|
||||
func (a *MeUserApiService) GetOwnUser(ctx context.Context) ApiGetOwnUserRequest {
|
||||
return ApiGetOwnUserRequest{
|
||||
@@ -51,7 +51,8 @@ func (a *MeUserApiService) GetOwnUser(ctx context.Context) ApiGetOwnUserRequest
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return User
|
||||
//
|
||||
// @return User
|
||||
func (a *MeUserApiService) GetOwnUserExecute(r ApiGetOwnUserRequest) (*User, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -155,8 +156,8 @@ func (r ApiUpdateOwnUserRequest) Execute() (*User, *http.Response, error) {
|
||||
/*
|
||||
UpdateOwnUser Update the current user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiUpdateOwnUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiUpdateOwnUserRequest
|
||||
*/
|
||||
func (a *MeUserApiService) UpdateOwnUser(ctx context.Context) ApiUpdateOwnUserRequest {
|
||||
return ApiUpdateOwnUserRequest{
|
||||
@@ -166,7 +167,8 @@ func (a *MeUserApiService) UpdateOwnUser(ctx context.Context) ApiUpdateOwnUserRe
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return User
|
||||
//
|
||||
// @return User
|
||||
func (a *MeUserApiService) UpdateOwnUserExecute(r ApiUpdateOwnUserRequest) (*User, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+9
-9
@@ -37,10 +37,9 @@ GetPermissionRoleDefinition Get unifiedRoleDefinition
|
||||
|
||||
Read the properties and relationships of a `unifiedRoleDefinition` object.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param roleId key: id of roleDefinition
|
||||
@return ApiGetPermissionRoleDefinitionRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param roleId key: id of roleDefinition
|
||||
@return ApiGetPermissionRoleDefinitionRequest
|
||||
*/
|
||||
func (a *RoleManagementApiService) GetPermissionRoleDefinition(ctx context.Context, roleId string) ApiGetPermissionRoleDefinitionRequest {
|
||||
return ApiGetPermissionRoleDefinitionRequest{
|
||||
@@ -51,7 +50,8 @@ func (a *RoleManagementApiService) GetPermissionRoleDefinition(ctx context.Conte
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return UnifiedRoleDefinition
|
||||
//
|
||||
// @return UnifiedRoleDefinition
|
||||
func (a *RoleManagementApiService) GetPermissionRoleDefinitionExecute(r ApiGetPermissionRoleDefinitionRequest) (*UnifiedRoleDefinition, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -148,9 +148,8 @@ ListPermissionRoleDefinitions List roleDefinitions
|
||||
|
||||
Get a list of `unifiedRoleDefinition` objects for the permissions provider. This list determines the roles that can be selected when creating sharing invites.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListPermissionRoleDefinitionsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListPermissionRoleDefinitionsRequest
|
||||
*/
|
||||
func (a *RoleManagementApiService) ListPermissionRoleDefinitions(ctx context.Context) ApiListPermissionRoleDefinitionsRequest {
|
||||
return ApiListPermissionRoleDefinitionsRequest{
|
||||
@@ -160,7 +159,8 @@ func (a *RoleManagementApiService) ListPermissionRoleDefinitions(ctx context.Con
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return UnifiedRoleDefinition
|
||||
//
|
||||
// @return UnifiedRoleDefinition
|
||||
func (a *RoleManagementApiService) ListPermissionRoleDefinitionsExecute(r ApiListPermissionRoleDefinitionsRequest) (*UnifiedRoleDefinition, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+8
-7
@@ -39,8 +39,8 @@ func (r ApiAssignTagsRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
AssignTags Assign tags to a resource
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiAssignTagsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiAssignTagsRequest
|
||||
*/
|
||||
func (a *TagsApiService) AssignTags(ctx context.Context) ApiAssignTagsRequest {
|
||||
return ApiAssignTagsRequest{
|
||||
@@ -135,8 +135,8 @@ func (r ApiGetTagsRequest) Execute() (*CollectionOfTags, *http.Response, error)
|
||||
/*
|
||||
GetTags Get all known tags
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetTagsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiGetTagsRequest
|
||||
*/
|
||||
func (a *TagsApiService) GetTags(ctx context.Context) ApiGetTagsRequest {
|
||||
return ApiGetTagsRequest{
|
||||
@@ -146,7 +146,8 @@ func (a *TagsApiService) GetTags(ctx context.Context) ApiGetTagsRequest {
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfTags
|
||||
//
|
||||
// @return CollectionOfTags
|
||||
func (a *TagsApiService) GetTagsExecute(r ApiGetTagsRequest) (*CollectionOfTags, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -246,8 +247,8 @@ func (r ApiUnassignTagsRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
UnassignTags Unassign tags from a resource
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiUnassignTagsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiUnassignTagsRequest
|
||||
*/
|
||||
func (a *TagsApiService) UnassignTags(ctx context.Context) ApiUnassignTagsRequest {
|
||||
return ApiUnassignTagsRequest{
|
||||
|
||||
+16
-14
@@ -42,9 +42,9 @@ func (r ApiDeleteUserRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
DeleteUser Delete entity from users
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiDeleteUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiDeleteUserRequest
|
||||
*/
|
||||
func (a *UserApiService) DeleteUser(ctx context.Context, userId string) ApiDeleteUserRequest {
|
||||
return ApiDeleteUserRequest{
|
||||
@@ -150,9 +150,9 @@ func (r ApiExportPersonalDataRequest) Execute() (*http.Response, error) {
|
||||
/*
|
||||
ExportPersonalData export personal data of a user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiExportPersonalDataRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiExportPersonalDataRequest
|
||||
*/
|
||||
func (a *UserApiService) ExportPersonalData(ctx context.Context, userId string) ApiExportPersonalDataRequest {
|
||||
return ApiExportPersonalDataRequest{
|
||||
@@ -264,9 +264,9 @@ func (r ApiGetUserRequest) Execute() (*User, *http.Response, error) {
|
||||
/*
|
||||
GetUser Get entity from users by key
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiGetUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id or name of user
|
||||
@return ApiGetUserRequest
|
||||
*/
|
||||
func (a *UserApiService) GetUser(ctx context.Context, userId string) ApiGetUserRequest {
|
||||
return ApiGetUserRequest{
|
||||
@@ -277,7 +277,8 @@ func (a *UserApiService) GetUser(ctx context.Context, userId string) ApiGetUserR
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return User
|
||||
//
|
||||
// @return User
|
||||
func (a *UserApiService) GetUserExecute(r ApiGetUserRequest) (*User, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
@@ -386,9 +387,9 @@ func (r ApiUpdateUserRequest) Execute() (*User, *http.Response, error) {
|
||||
/*
|
||||
UpdateUser Update entity in users
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUpdateUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUpdateUserRequest
|
||||
*/
|
||||
func (a *UserApiService) UpdateUser(ctx context.Context, userId string) ApiUpdateUserRequest {
|
||||
return ApiUpdateUserRequest{
|
||||
@@ -399,7 +400,8 @@ func (a *UserApiService) UpdateUser(ctx context.Context, userId string) ApiUpdat
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return User
|
||||
//
|
||||
// @return User
|
||||
func (a *UserApiService) UpdateUserExecute(r ApiUpdateUserRequest) (*User, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPatch
|
||||
|
||||
+14
-13
@@ -47,10 +47,9 @@ Use this API to assign a global role to a user. To grant an app role assignment
|
||||
* `resourceId`: The `id` of the resource `servicePrincipal` or `application` that has defined the app role.
|
||||
* `appRoleId`: The `id` of the `appRole` (defined on the resource service principal or application) to assign to the user.
|
||||
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUserCreateAppRoleAssignmentsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUserCreateAppRoleAssignmentsRequest
|
||||
*/
|
||||
func (a *UserAppRoleAssignmentApiService) UserCreateAppRoleAssignments(ctx context.Context, userId string) ApiUserCreateAppRoleAssignmentsRequest {
|
||||
return ApiUserCreateAppRoleAssignmentsRequest{
|
||||
@@ -61,7 +60,8 @@ func (a *UserAppRoleAssignmentApiService) UserCreateAppRoleAssignments(ctx conte
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return AppRoleAssignment
|
||||
//
|
||||
// @return AppRoleAssignment
|
||||
func (a *UserAppRoleAssignmentApiService) UserCreateAppRoleAssignmentsExecute(r ApiUserCreateAppRoleAssignmentsRequest) (*AppRoleAssignment, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -170,10 +170,10 @@ func (r ApiUserDeleteAppRoleAssignmentsRequest) Execute() (*http.Response, error
|
||||
/*
|
||||
UserDeleteAppRoleAssignments Delete the appRoleAssignment from a user
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@param appRoleAssignmentId key: id of appRoleAssignment. This is the concatenated {user-id}:{appRole-id} separated by a colon.
|
||||
@return ApiUserDeleteAppRoleAssignmentsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@param appRoleAssignmentId key: id of appRoleAssignment. This is the concatenated {user-id}:{appRole-id} separated by a colon.
|
||||
@return ApiUserDeleteAppRoleAssignmentsRequest
|
||||
*/
|
||||
func (a *UserAppRoleAssignmentApiService) UserDeleteAppRoleAssignments(ctx context.Context, userId string, appRoleAssignmentId string) ApiUserDeleteAppRoleAssignmentsRequest {
|
||||
return ApiUserDeleteAppRoleAssignmentsRequest{
|
||||
@@ -276,9 +276,9 @@ UserListAppRoleAssignments Get appRoleAssignments from a user
|
||||
|
||||
Represents the global roles a user has been granted for an application.
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUserListAppRoleAssignmentsRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@param userId key: id of user
|
||||
@return ApiUserListAppRoleAssignmentsRequest
|
||||
*/
|
||||
func (a *UserAppRoleAssignmentApiService) UserListAppRoleAssignments(ctx context.Context, userId string) ApiUserListAppRoleAssignmentsRequest {
|
||||
return ApiUserListAppRoleAssignmentsRequest{
|
||||
@@ -289,7 +289,8 @@ func (a *UserAppRoleAssignmentApiService) UserListAppRoleAssignments(ctx context
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfAppRoleAssignments
|
||||
//
|
||||
// @return CollectionOfAppRoleAssignments
|
||||
func (a *UserAppRoleAssignmentApiService) UserListAppRoleAssignmentsExecute(r ApiUserListAppRoleAssignmentsRequest) (*CollectionOfAppRoleAssignments, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+8
-6
@@ -40,8 +40,8 @@ func (r ApiCreateUserRequest) Execute() (*User, *http.Response, error) {
|
||||
/*
|
||||
CreateUser Add new entity to users
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateUserRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiCreateUserRequest
|
||||
*/
|
||||
func (a *UsersApiService) CreateUser(ctx context.Context) ApiCreateUserRequest {
|
||||
return ApiCreateUserRequest{
|
||||
@@ -51,7 +51,8 @@ func (a *UsersApiService) CreateUser(ctx context.Context) ApiCreateUserRequest {
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return User
|
||||
//
|
||||
// @return User
|
||||
func (a *UsersApiService) CreateUserExecute(r ApiCreateUserRequest) (*User, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodPost
|
||||
@@ -185,8 +186,8 @@ func (r ApiListUsersRequest) Execute() (*CollectionOfUser, *http.Response, error
|
||||
/*
|
||||
ListUsers Get entities from users
|
||||
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListUsersRequest
|
||||
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@return ApiListUsersRequest
|
||||
*/
|
||||
func (a *UsersApiService) ListUsers(ctx context.Context) ApiListUsersRequest {
|
||||
return ApiListUsersRequest{
|
||||
@@ -196,7 +197,8 @@ func (a *UsersApiService) ListUsers(ctx context.Context) ApiListUsersRequest {
|
||||
}
|
||||
|
||||
// Execute executes the request
|
||||
// @return CollectionOfUser
|
||||
//
|
||||
// @return CollectionOfUser
|
||||
func (a *UsersApiService) ListUsersExecute(r ApiListUsersRequest) (*CollectionOfUser, *http.Response, error) {
|
||||
var (
|
||||
localVarHTTPMethod = http.MethodGet
|
||||
|
||||
+12
-9
@@ -34,8 +34,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
jsonCheck = regexp.MustCompile(`(?i:(?:application|text)/(?:vnd\.[^;]+\+)?json)`)
|
||||
xmlCheck = regexp.MustCompile(`(?i:(?:application|text)/xml)`)
|
||||
JsonCheck = regexp.MustCompile(`(?i:(?:application|text)/(?:[^;]+\+)?json)`)
|
||||
XmlCheck = regexp.MustCompile(`(?i:(?:application|text)/(?:[^;]+\+)?xml)`)
|
||||
queryParamSplit = regexp.MustCompile(`(^|&)([^&]+)`)
|
||||
queryDescape = strings.NewReplacer("%5B", "[", "%5D", "]")
|
||||
)
|
||||
@@ -227,7 +227,7 @@ func parameterAddToHeaderOrQuery(headerOrQueryParams interface{}, keyPrefix stri
|
||||
return
|
||||
}
|
||||
if t, ok := obj.(time.Time); ok {
|
||||
parameterAddToHeaderOrQuery(headerOrQueryParams, keyPrefix, t.Format(time.RFC3339), collectionType)
|
||||
parameterAddToHeaderOrQuery(headerOrQueryParams, keyPrefix, t.Format(time.RFC3339Nano), collectionType)
|
||||
return
|
||||
}
|
||||
value = v.Type().String() + " value"
|
||||
@@ -475,6 +475,11 @@ func (c *APIClient) prepareRequest(
|
||||
|
||||
// Walk through any authentication.
|
||||
|
||||
// Basic HTTP Authentication
|
||||
if auth, ok := ctx.Value(ContextBasicAuth).(BasicAuth); ok {
|
||||
localVarRequest.SetBasicAuth(auth.UserName, auth.Password)
|
||||
}
|
||||
|
||||
// AccessToken Authentication
|
||||
if auth, ok := ctx.Value(ContextAccessToken).(string); ok {
|
||||
localVarRequest.Header.Add("Authorization", "Bearer "+auth)
|
||||
@@ -506,7 +511,6 @@ func (c *APIClient) decode(v interface{}, b []byte, contentType string) (err err
|
||||
return
|
||||
}
|
||||
_, err = f.Seek(0, io.SeekStart)
|
||||
err = os.Remove(f.Name())
|
||||
return
|
||||
}
|
||||
if f, ok := v.(**os.File); ok {
|
||||
@@ -519,16 +523,15 @@ func (c *APIClient) decode(v interface{}, b []byte, contentType string) (err err
|
||||
return
|
||||
}
|
||||
_, err = (*f).Seek(0, io.SeekStart)
|
||||
err = os.Remove((*f).Name())
|
||||
return
|
||||
}
|
||||
if xmlCheck.MatchString(contentType) {
|
||||
if XmlCheck.MatchString(contentType) {
|
||||
if err = xml.Unmarshal(b, v); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
if jsonCheck.MatchString(contentType) {
|
||||
if JsonCheck.MatchString(contentType) {
|
||||
if actualObj, ok := v.(interface{ GetActualInstance() interface{} }); ok { // oneOf, anyOf schemas
|
||||
if unmarshalObj, ok := actualObj.(interface{ UnmarshalJSON([]byte) error }); ok { // make sure it has UnmarshalJSON defined
|
||||
if err = unmarshalObj.UnmarshalJSON(b); err != nil {
|
||||
@@ -593,9 +596,9 @@ func setBody(body interface{}, contentType string) (bodyBuf *bytes.Buffer, err e
|
||||
_, err = bodyBuf.WriteString(s)
|
||||
} else if s, ok := body.(*string); ok {
|
||||
_, err = bodyBuf.WriteString(*s)
|
||||
} else if jsonCheck.MatchString(contentType) {
|
||||
} else if JsonCheck.MatchString(contentType) {
|
||||
err = json.NewEncoder(bodyBuf).Encode(body)
|
||||
} else if xmlCheck.MatchString(contentType) {
|
||||
} else if XmlCheck.MatchString(contentType) {
|
||||
var bs []byte
|
||||
bs, err = xml.Marshal(body)
|
||||
if err == nil {
|
||||
|
||||
+3
@@ -28,6 +28,9 @@ func (c contextKey) String() string {
|
||||
}
|
||||
|
||||
var (
|
||||
// ContextBasicAuth takes BasicAuth as authentication for the request.
|
||||
ContextBasicAuth = contextKey("basic")
|
||||
|
||||
// ContextAccessToken takes a string oauth2 access token as authentication for the request.
|
||||
ContextAccessToken = contextKey("accesstoken")
|
||||
|
||||
|
||||
+41
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the AppRole type satisfies the MappedNullable interface at compile time
|
||||
@@ -29,6 +31,8 @@ type AppRole struct {
|
||||
Id string `json:"id"`
|
||||
}
|
||||
|
||||
type _AppRole AppRole
|
||||
|
||||
// NewAppRole instantiates a new AppRole object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -212,6 +216,43 @@ func (o AppRole) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *AppRole) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"id",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varAppRole := _AppRole{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varAppRole)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = AppRole(varAppRole)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableAppRole struct {
|
||||
value *AppRole
|
||||
isSet bool
|
||||
|
||||
+43
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"time"
|
||||
)
|
||||
|
||||
@@ -39,6 +41,8 @@ type AppRoleAssignment struct {
|
||||
ResourceId NullableString `json:"resourceId"`
|
||||
}
|
||||
|
||||
type _AppRoleAssignment AppRoleAssignment
|
||||
|
||||
// NewAppRoleAssignment instantiates a new AppRoleAssignment object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -405,6 +409,45 @@ func (o AppRoleAssignment) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *AppRoleAssignment) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"appRoleId",
|
||||
"principalId",
|
||||
"resourceId",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varAppRoleAssignment := _AppRoleAssignment{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varAppRoleAssignment)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = AppRoleAssignment(varAppRoleAssignment)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableAppRoleAssignment struct {
|
||||
value *AppRoleAssignment
|
||||
isSet bool
|
||||
|
||||
+41
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the Application type satisfies the MappedNullable interface at compile time
|
||||
@@ -27,6 +29,8 @@ type Application struct {
|
||||
DisplayName NullableString `json:"displayName,omitempty"`
|
||||
}
|
||||
|
||||
type _Application Application
|
||||
|
||||
// NewApplication instantiates a new Application object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -164,6 +168,43 @@ func (o Application) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *Application) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"id",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varApplication := _Application{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varApplication)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = Application(varApplication)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableApplication struct {
|
||||
value *Application
|
||||
isSet bool
|
||||
|
||||
+41
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"time"
|
||||
)
|
||||
|
||||
@@ -50,6 +52,8 @@ type Drive struct {
|
||||
Special []DriveItem `json:"special,omitempty"`
|
||||
}
|
||||
|
||||
type _Drive Drive
|
||||
|
||||
// NewDrive instantiates a new Drive object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -666,6 +670,43 @@ func (o Drive) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *Drive) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"name",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varDrive := _Drive{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varDrive)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = Drive(varDrive)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableDrive struct {
|
||||
value *Drive
|
||||
isSet bool
|
||||
|
||||
+712
@@ -0,0 +1,712 @@
|
||||
/*
|
||||
Libre Graph API
|
||||
|
||||
Libre Graph is a free API for cloud collaboration inspired by the MS Graph API.
|
||||
|
||||
API version: v1.0.4
|
||||
*/
|
||||
|
||||
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
||||
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"time"
|
||||
)
|
||||
|
||||
// checks if the DriveUpdate type satisfies the MappedNullable interface at compile time
|
||||
var _ MappedNullable = &DriveUpdate{}
|
||||
|
||||
// DriveUpdate The drive represents an update to a space on the storage.
|
||||
type DriveUpdate struct {
|
||||
// The unique idenfier for this drive.
|
||||
Id *string `json:"id,omitempty"`
|
||||
CreatedBy *IdentitySet `json:"createdBy,omitempty"`
|
||||
// Date and time of item creation. Read-only.
|
||||
CreatedDateTime *time.Time `json:"createdDateTime,omitempty"`
|
||||
// Provides a user-visible description of the item. Optional.
|
||||
Description *string `json:"description,omitempty"`
|
||||
// ETag for the item. Read-only.
|
||||
ETag *string `json:"eTag,omitempty"`
|
||||
LastModifiedBy *IdentitySet `json:"lastModifiedBy,omitempty"`
|
||||
// Date and time the item was last modified. Read-only.
|
||||
LastModifiedDateTime *time.Time `json:"lastModifiedDateTime,omitempty"`
|
||||
// The name of the item. Read-write.
|
||||
Name *string `json:"name,omitempty"`
|
||||
ParentReference *ItemReference `json:"parentReference,omitempty"`
|
||||
// URL that displays the resource in the browser. Read-only.
|
||||
WebUrl *string `json:"webUrl,omitempty"`
|
||||
// Describes the type of drive represented by this resource. Values are \"personal\" for users home spaces, \"project\", \"virtual\" or \"share\". Read-only.
|
||||
DriveType *string `json:"driveType,omitempty"`
|
||||
// The drive alias can be used in clients to make the urls user friendly. Example: 'personal/einstein'. This will be used to resolve to the correct driveID.
|
||||
DriveAlias *string `json:"driveAlias,omitempty"`
|
||||
Owner *IdentitySet `json:"owner,omitempty"`
|
||||
Quota *Quota `json:"quota,omitempty"`
|
||||
// All items contained in the drive. Read-only. Nullable.
|
||||
Items []DriveItem `json:"items,omitempty"`
|
||||
Root *DriveItem `json:"root,omitempty"`
|
||||
// A collection of special drive resources.
|
||||
Special []DriveItem `json:"special,omitempty"`
|
||||
}
|
||||
|
||||
// NewDriveUpdate instantiates a new DriveUpdate object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
// will change when the set of required properties is changed
|
||||
func NewDriveUpdate() *DriveUpdate {
|
||||
this := DriveUpdate{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// NewDriveUpdateWithDefaults instantiates a new DriveUpdate object
|
||||
// This constructor will only assign default values to properties that have it defined,
|
||||
// but it doesn't guarantee that properties required by API are set
|
||||
func NewDriveUpdateWithDefaults() *DriveUpdate {
|
||||
this := DriveUpdate{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// GetId returns the Id field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetId() string {
|
||||
if o == nil || IsNil(o.Id) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Id
|
||||
}
|
||||
|
||||
// GetIdOk returns a tuple with the Id field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetIdOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Id) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Id, true
|
||||
}
|
||||
|
||||
// HasId returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasId() bool {
|
||||
if o != nil && !IsNil(o.Id) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetId gets a reference to the given string and assigns it to the Id field.
|
||||
func (o *DriveUpdate) SetId(v string) {
|
||||
o.Id = &v
|
||||
}
|
||||
|
||||
// GetCreatedBy returns the CreatedBy field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetCreatedBy() IdentitySet {
|
||||
if o == nil || IsNil(o.CreatedBy) {
|
||||
var ret IdentitySet
|
||||
return ret
|
||||
}
|
||||
return *o.CreatedBy
|
||||
}
|
||||
|
||||
// GetCreatedByOk returns a tuple with the CreatedBy field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetCreatedByOk() (*IdentitySet, bool) {
|
||||
if o == nil || IsNil(o.CreatedBy) {
|
||||
return nil, false
|
||||
}
|
||||
return o.CreatedBy, true
|
||||
}
|
||||
|
||||
// HasCreatedBy returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasCreatedBy() bool {
|
||||
if o != nil && !IsNil(o.CreatedBy) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetCreatedBy gets a reference to the given IdentitySet and assigns it to the CreatedBy field.
|
||||
func (o *DriveUpdate) SetCreatedBy(v IdentitySet) {
|
||||
o.CreatedBy = &v
|
||||
}
|
||||
|
||||
// GetCreatedDateTime returns the CreatedDateTime field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetCreatedDateTime() time.Time {
|
||||
if o == nil || IsNil(o.CreatedDateTime) {
|
||||
var ret time.Time
|
||||
return ret
|
||||
}
|
||||
return *o.CreatedDateTime
|
||||
}
|
||||
|
||||
// GetCreatedDateTimeOk returns a tuple with the CreatedDateTime field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetCreatedDateTimeOk() (*time.Time, bool) {
|
||||
if o == nil || IsNil(o.CreatedDateTime) {
|
||||
return nil, false
|
||||
}
|
||||
return o.CreatedDateTime, true
|
||||
}
|
||||
|
||||
// HasCreatedDateTime returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasCreatedDateTime() bool {
|
||||
if o != nil && !IsNil(o.CreatedDateTime) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetCreatedDateTime gets a reference to the given time.Time and assigns it to the CreatedDateTime field.
|
||||
func (o *DriveUpdate) SetCreatedDateTime(v time.Time) {
|
||||
o.CreatedDateTime = &v
|
||||
}
|
||||
|
||||
// GetDescription returns the Description field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetDescription() string {
|
||||
if o == nil || IsNil(o.Description) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Description
|
||||
}
|
||||
|
||||
// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetDescriptionOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Description) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Description, true
|
||||
}
|
||||
|
||||
// HasDescription returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasDescription() bool {
|
||||
if o != nil && !IsNil(o.Description) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetDescription gets a reference to the given string and assigns it to the Description field.
|
||||
func (o *DriveUpdate) SetDescription(v string) {
|
||||
o.Description = &v
|
||||
}
|
||||
|
||||
// GetETag returns the ETag field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetETag() string {
|
||||
if o == nil || IsNil(o.ETag) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.ETag
|
||||
}
|
||||
|
||||
// GetETagOk returns a tuple with the ETag field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetETagOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.ETag) {
|
||||
return nil, false
|
||||
}
|
||||
return o.ETag, true
|
||||
}
|
||||
|
||||
// HasETag returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasETag() bool {
|
||||
if o != nil && !IsNil(o.ETag) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetETag gets a reference to the given string and assigns it to the ETag field.
|
||||
func (o *DriveUpdate) SetETag(v string) {
|
||||
o.ETag = &v
|
||||
}
|
||||
|
||||
// GetLastModifiedBy returns the LastModifiedBy field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetLastModifiedBy() IdentitySet {
|
||||
if o == nil || IsNil(o.LastModifiedBy) {
|
||||
var ret IdentitySet
|
||||
return ret
|
||||
}
|
||||
return *o.LastModifiedBy
|
||||
}
|
||||
|
||||
// GetLastModifiedByOk returns a tuple with the LastModifiedBy field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetLastModifiedByOk() (*IdentitySet, bool) {
|
||||
if o == nil || IsNil(o.LastModifiedBy) {
|
||||
return nil, false
|
||||
}
|
||||
return o.LastModifiedBy, true
|
||||
}
|
||||
|
||||
// HasLastModifiedBy returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasLastModifiedBy() bool {
|
||||
if o != nil && !IsNil(o.LastModifiedBy) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetLastModifiedBy gets a reference to the given IdentitySet and assigns it to the LastModifiedBy field.
|
||||
func (o *DriveUpdate) SetLastModifiedBy(v IdentitySet) {
|
||||
o.LastModifiedBy = &v
|
||||
}
|
||||
|
||||
// GetLastModifiedDateTime returns the LastModifiedDateTime field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetLastModifiedDateTime() time.Time {
|
||||
if o == nil || IsNil(o.LastModifiedDateTime) {
|
||||
var ret time.Time
|
||||
return ret
|
||||
}
|
||||
return *o.LastModifiedDateTime
|
||||
}
|
||||
|
||||
// GetLastModifiedDateTimeOk returns a tuple with the LastModifiedDateTime field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetLastModifiedDateTimeOk() (*time.Time, bool) {
|
||||
if o == nil || IsNil(o.LastModifiedDateTime) {
|
||||
return nil, false
|
||||
}
|
||||
return o.LastModifiedDateTime, true
|
||||
}
|
||||
|
||||
// HasLastModifiedDateTime returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasLastModifiedDateTime() bool {
|
||||
if o != nil && !IsNil(o.LastModifiedDateTime) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetLastModifiedDateTime gets a reference to the given time.Time and assigns it to the LastModifiedDateTime field.
|
||||
func (o *DriveUpdate) SetLastModifiedDateTime(v time.Time) {
|
||||
o.LastModifiedDateTime = &v
|
||||
}
|
||||
|
||||
// GetName returns the Name field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetName() string {
|
||||
if o == nil || IsNil(o.Name) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Name
|
||||
}
|
||||
|
||||
// GetNameOk returns a tuple with the Name field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetNameOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Name) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Name, true
|
||||
}
|
||||
|
||||
// HasName returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasName() bool {
|
||||
if o != nil && !IsNil(o.Name) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetName gets a reference to the given string and assigns it to the Name field.
|
||||
func (o *DriveUpdate) SetName(v string) {
|
||||
o.Name = &v
|
||||
}
|
||||
|
||||
// GetParentReference returns the ParentReference field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetParentReference() ItemReference {
|
||||
if o == nil || IsNil(o.ParentReference) {
|
||||
var ret ItemReference
|
||||
return ret
|
||||
}
|
||||
return *o.ParentReference
|
||||
}
|
||||
|
||||
// GetParentReferenceOk returns a tuple with the ParentReference field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetParentReferenceOk() (*ItemReference, bool) {
|
||||
if o == nil || IsNil(o.ParentReference) {
|
||||
return nil, false
|
||||
}
|
||||
return o.ParentReference, true
|
||||
}
|
||||
|
||||
// HasParentReference returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasParentReference() bool {
|
||||
if o != nil && !IsNil(o.ParentReference) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetParentReference gets a reference to the given ItemReference and assigns it to the ParentReference field.
|
||||
func (o *DriveUpdate) SetParentReference(v ItemReference) {
|
||||
o.ParentReference = &v
|
||||
}
|
||||
|
||||
// GetWebUrl returns the WebUrl field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetWebUrl() string {
|
||||
if o == nil || IsNil(o.WebUrl) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.WebUrl
|
||||
}
|
||||
|
||||
// GetWebUrlOk returns a tuple with the WebUrl field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetWebUrlOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.WebUrl) {
|
||||
return nil, false
|
||||
}
|
||||
return o.WebUrl, true
|
||||
}
|
||||
|
||||
// HasWebUrl returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasWebUrl() bool {
|
||||
if o != nil && !IsNil(o.WebUrl) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetWebUrl gets a reference to the given string and assigns it to the WebUrl field.
|
||||
func (o *DriveUpdate) SetWebUrl(v string) {
|
||||
o.WebUrl = &v
|
||||
}
|
||||
|
||||
// GetDriveType returns the DriveType field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetDriveType() string {
|
||||
if o == nil || IsNil(o.DriveType) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.DriveType
|
||||
}
|
||||
|
||||
// GetDriveTypeOk returns a tuple with the DriveType field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetDriveTypeOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.DriveType) {
|
||||
return nil, false
|
||||
}
|
||||
return o.DriveType, true
|
||||
}
|
||||
|
||||
// HasDriveType returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasDriveType() bool {
|
||||
if o != nil && !IsNil(o.DriveType) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetDriveType gets a reference to the given string and assigns it to the DriveType field.
|
||||
func (o *DriveUpdate) SetDriveType(v string) {
|
||||
o.DriveType = &v
|
||||
}
|
||||
|
||||
// GetDriveAlias returns the DriveAlias field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetDriveAlias() string {
|
||||
if o == nil || IsNil(o.DriveAlias) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.DriveAlias
|
||||
}
|
||||
|
||||
// GetDriveAliasOk returns a tuple with the DriveAlias field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetDriveAliasOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.DriveAlias) {
|
||||
return nil, false
|
||||
}
|
||||
return o.DriveAlias, true
|
||||
}
|
||||
|
||||
// HasDriveAlias returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasDriveAlias() bool {
|
||||
if o != nil && !IsNil(o.DriveAlias) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetDriveAlias gets a reference to the given string and assigns it to the DriveAlias field.
|
||||
func (o *DriveUpdate) SetDriveAlias(v string) {
|
||||
o.DriveAlias = &v
|
||||
}
|
||||
|
||||
// GetOwner returns the Owner field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetOwner() IdentitySet {
|
||||
if o == nil || IsNil(o.Owner) {
|
||||
var ret IdentitySet
|
||||
return ret
|
||||
}
|
||||
return *o.Owner
|
||||
}
|
||||
|
||||
// GetOwnerOk returns a tuple with the Owner field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetOwnerOk() (*IdentitySet, bool) {
|
||||
if o == nil || IsNil(o.Owner) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Owner, true
|
||||
}
|
||||
|
||||
// HasOwner returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasOwner() bool {
|
||||
if o != nil && !IsNil(o.Owner) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetOwner gets a reference to the given IdentitySet and assigns it to the Owner field.
|
||||
func (o *DriveUpdate) SetOwner(v IdentitySet) {
|
||||
o.Owner = &v
|
||||
}
|
||||
|
||||
// GetQuota returns the Quota field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetQuota() Quota {
|
||||
if o == nil || IsNil(o.Quota) {
|
||||
var ret Quota
|
||||
return ret
|
||||
}
|
||||
return *o.Quota
|
||||
}
|
||||
|
||||
// GetQuotaOk returns a tuple with the Quota field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetQuotaOk() (*Quota, bool) {
|
||||
if o == nil || IsNil(o.Quota) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Quota, true
|
||||
}
|
||||
|
||||
// HasQuota returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasQuota() bool {
|
||||
if o != nil && !IsNil(o.Quota) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetQuota gets a reference to the given Quota and assigns it to the Quota field.
|
||||
func (o *DriveUpdate) SetQuota(v Quota) {
|
||||
o.Quota = &v
|
||||
}
|
||||
|
||||
// GetItems returns the Items field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetItems() []DriveItem {
|
||||
if o == nil || IsNil(o.Items) {
|
||||
var ret []DriveItem
|
||||
return ret
|
||||
}
|
||||
return o.Items
|
||||
}
|
||||
|
||||
// GetItemsOk returns a tuple with the Items field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetItemsOk() ([]DriveItem, bool) {
|
||||
if o == nil || IsNil(o.Items) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Items, true
|
||||
}
|
||||
|
||||
// HasItems returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasItems() bool {
|
||||
if o != nil && !IsNil(o.Items) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetItems gets a reference to the given []DriveItem and assigns it to the Items field.
|
||||
func (o *DriveUpdate) SetItems(v []DriveItem) {
|
||||
o.Items = v
|
||||
}
|
||||
|
||||
// GetRoot returns the Root field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetRoot() DriveItem {
|
||||
if o == nil || IsNil(o.Root) {
|
||||
var ret DriveItem
|
||||
return ret
|
||||
}
|
||||
return *o.Root
|
||||
}
|
||||
|
||||
// GetRootOk returns a tuple with the Root field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetRootOk() (*DriveItem, bool) {
|
||||
if o == nil || IsNil(o.Root) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Root, true
|
||||
}
|
||||
|
||||
// HasRoot returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasRoot() bool {
|
||||
if o != nil && !IsNil(o.Root) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetRoot gets a reference to the given DriveItem and assigns it to the Root field.
|
||||
func (o *DriveUpdate) SetRoot(v DriveItem) {
|
||||
o.Root = &v
|
||||
}
|
||||
|
||||
// GetSpecial returns the Special field value if set, zero value otherwise.
|
||||
func (o *DriveUpdate) GetSpecial() []DriveItem {
|
||||
if o == nil || IsNil(o.Special) {
|
||||
var ret []DriveItem
|
||||
return ret
|
||||
}
|
||||
return o.Special
|
||||
}
|
||||
|
||||
// GetSpecialOk returns a tuple with the Special field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *DriveUpdate) GetSpecialOk() ([]DriveItem, bool) {
|
||||
if o == nil || IsNil(o.Special) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Special, true
|
||||
}
|
||||
|
||||
// HasSpecial returns a boolean if a field has been set.
|
||||
func (o *DriveUpdate) HasSpecial() bool {
|
||||
if o != nil && !IsNil(o.Special) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetSpecial gets a reference to the given []DriveItem and assigns it to the Special field.
|
||||
func (o *DriveUpdate) SetSpecial(v []DriveItem) {
|
||||
o.Special = v
|
||||
}
|
||||
|
||||
func (o DriveUpdate) MarshalJSON() ([]byte, error) {
|
||||
toSerialize, err := o.ToMap()
|
||||
if err != nil {
|
||||
return []byte{}, err
|
||||
}
|
||||
return json.Marshal(toSerialize)
|
||||
}
|
||||
|
||||
func (o DriveUpdate) ToMap() (map[string]interface{}, error) {
|
||||
toSerialize := map[string]interface{}{}
|
||||
if !IsNil(o.Id) {
|
||||
toSerialize["id"] = o.Id
|
||||
}
|
||||
if !IsNil(o.CreatedBy) {
|
||||
toSerialize["createdBy"] = o.CreatedBy
|
||||
}
|
||||
if !IsNil(o.CreatedDateTime) {
|
||||
toSerialize["createdDateTime"] = o.CreatedDateTime
|
||||
}
|
||||
if !IsNil(o.Description) {
|
||||
toSerialize["description"] = o.Description
|
||||
}
|
||||
if !IsNil(o.ETag) {
|
||||
toSerialize["eTag"] = o.ETag
|
||||
}
|
||||
if !IsNil(o.LastModifiedBy) {
|
||||
toSerialize["lastModifiedBy"] = o.LastModifiedBy
|
||||
}
|
||||
if !IsNil(o.LastModifiedDateTime) {
|
||||
toSerialize["lastModifiedDateTime"] = o.LastModifiedDateTime
|
||||
}
|
||||
if !IsNil(o.Name) {
|
||||
toSerialize["name"] = o.Name
|
||||
}
|
||||
if !IsNil(o.ParentReference) {
|
||||
toSerialize["parentReference"] = o.ParentReference
|
||||
}
|
||||
if !IsNil(o.WebUrl) {
|
||||
toSerialize["webUrl"] = o.WebUrl
|
||||
}
|
||||
if !IsNil(o.DriveType) {
|
||||
toSerialize["driveType"] = o.DriveType
|
||||
}
|
||||
if !IsNil(o.DriveAlias) {
|
||||
toSerialize["driveAlias"] = o.DriveAlias
|
||||
}
|
||||
if !IsNil(o.Owner) {
|
||||
toSerialize["owner"] = o.Owner
|
||||
}
|
||||
if !IsNil(o.Quota) {
|
||||
toSerialize["quota"] = o.Quota
|
||||
}
|
||||
if !IsNil(o.Items) {
|
||||
toSerialize["items"] = o.Items
|
||||
}
|
||||
if !IsNil(o.Root) {
|
||||
toSerialize["root"] = o.Root
|
||||
}
|
||||
if !IsNil(o.Special) {
|
||||
toSerialize["special"] = o.Special
|
||||
}
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
type NullableDriveUpdate struct {
|
||||
value *DriveUpdate
|
||||
isSet bool
|
||||
}
|
||||
|
||||
func (v NullableDriveUpdate) Get() *DriveUpdate {
|
||||
return v.value
|
||||
}
|
||||
|
||||
func (v *NullableDriveUpdate) Set(val *DriveUpdate) {
|
||||
v.value = val
|
||||
v.isSet = true
|
||||
}
|
||||
|
||||
func (v NullableDriveUpdate) IsSet() bool {
|
||||
return v.isSet
|
||||
}
|
||||
|
||||
func (v *NullableDriveUpdate) Unset() {
|
||||
v.value = nil
|
||||
v.isSet = false
|
||||
}
|
||||
|
||||
func NewNullableDriveUpdate(val *DriveUpdate) *NullableDriveUpdate {
|
||||
return &NullableDriveUpdate{value: val, isSet: true}
|
||||
}
|
||||
|
||||
func (v NullableDriveUpdate) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableDriveUpdate) UnmarshalJSON(src []byte) error {
|
||||
v.isSet = true
|
||||
return json.Unmarshal(src, &v.value)
|
||||
}
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the EducationClass type satisfies the MappedNullable interface at compile time
|
||||
@@ -35,6 +37,8 @@ type EducationClass struct {
|
||||
ExternalId *string `json:"externalId,omitempty"`
|
||||
}
|
||||
|
||||
type _EducationClass EducationClass
|
||||
|
||||
// NewEducationClass instantiates a new EducationClass object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -292,6 +296,44 @@ func (o EducationClass) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *EducationClass) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"displayName",
|
||||
"classification",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varEducationClass := _EducationClass{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varEducationClass)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = EducationClass(varEducationClass)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableEducationClass struct {
|
||||
value *EducationClass
|
||||
isSet bool
|
||||
|
||||
+41
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the Identity type satisfies the MappedNullable interface at compile time
|
||||
@@ -25,6 +27,8 @@ type Identity struct {
|
||||
Id *string `json:"id,omitempty"`
|
||||
}
|
||||
|
||||
type _Identity Identity
|
||||
|
||||
// NewIdentity instantiates a new Identity object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -116,6 +120,43 @@ func (o Identity) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *Identity) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"displayName",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varIdentity := _Identity{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varIdentity)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = Identity(varIdentity)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableIdentity struct {
|
||||
value *Identity
|
||||
isSet bool
|
||||
|
||||
+41
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the OdataError type satisfies the MappedNullable interface at compile time
|
||||
@@ -22,6 +24,8 @@ type OdataError struct {
|
||||
Error OdataErrorMain `json:"error"`
|
||||
}
|
||||
|
||||
type _OdataError OdataError
|
||||
|
||||
// NewOdataError instantiates a new OdataError object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -78,6 +82,43 @@ func (o OdataError) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *OdataError) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"error",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varOdataError := _OdataError{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varOdataError)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = OdataError(varOdataError)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableOdataError struct {
|
||||
value *OdataError
|
||||
isSet bool
|
||||
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the OdataErrorDetail type satisfies the MappedNullable interface at compile time
|
||||
@@ -24,6 +26,8 @@ type OdataErrorDetail struct {
|
||||
Target *string `json:"target,omitempty"`
|
||||
}
|
||||
|
||||
type _OdataErrorDetail OdataErrorDetail
|
||||
|
||||
// NewOdataErrorDetail instantiates a new OdataErrorDetail object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -141,6 +145,44 @@ func (o OdataErrorDetail) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *OdataErrorDetail) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"code",
|
||||
"message",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varOdataErrorDetail := _OdataErrorDetail{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varOdataErrorDetail)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = OdataErrorDetail(varOdataErrorDetail)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableOdataErrorDetail struct {
|
||||
value *OdataErrorDetail
|
||||
isSet bool
|
||||
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the OdataErrorMain type satisfies the MappedNullable interface at compile time
|
||||
@@ -27,6 +29,8 @@ type OdataErrorMain struct {
|
||||
Innererror map[string]interface{} `json:"innererror,omitempty"`
|
||||
}
|
||||
|
||||
type _OdataErrorMain OdataErrorMain
|
||||
|
||||
// NewOdataErrorMain instantiates a new OdataErrorMain object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -214,6 +218,44 @@ func (o OdataErrorMain) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *OdataErrorMain) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"code",
|
||||
"message",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varOdataErrorMain := _OdataErrorMain{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varOdataErrorMain)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = OdataErrorMain(varOdataErrorMain)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableOdataErrorMain struct {
|
||||
value *OdataErrorMain
|
||||
isSet bool
|
||||
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the PasswordChange type satisfies the MappedNullable interface at compile time
|
||||
@@ -23,6 +25,8 @@ type PasswordChange struct {
|
||||
NewPassword string `json:"newPassword"`
|
||||
}
|
||||
|
||||
type _PasswordChange PasswordChange
|
||||
|
||||
// NewPasswordChange instantiates a new PasswordChange object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -105,6 +109,44 @@ func (o PasswordChange) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *PasswordChange) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"currentPassword",
|
||||
"newPassword",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varPasswordChange := _PasswordChange{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varPasswordChange)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = PasswordChange(varPasswordChange)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullablePasswordChange struct {
|
||||
value *PasswordChange
|
||||
isSet bool
|
||||
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the TagAssignment type satisfies the MappedNullable interface at compile time
|
||||
@@ -23,6 +25,8 @@ type TagAssignment struct {
|
||||
Tags []string `json:"tags"`
|
||||
}
|
||||
|
||||
type _TagAssignment TagAssignment
|
||||
|
||||
// NewTagAssignment instantiates a new TagAssignment object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -105,6 +109,44 @@ func (o TagAssignment) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *TagAssignment) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"resourceId",
|
||||
"tags",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varTagAssignment := _TagAssignment{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varTagAssignment)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = TagAssignment(varTagAssignment)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableTagAssignment struct {
|
||||
value *TagAssignment
|
||||
isSet bool
|
||||
|
||||
+42
@@ -11,7 +11,9 @@ API version: v1.0.4
|
||||
package libregraph
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// checks if the TagUnassignment type satisfies the MappedNullable interface at compile time
|
||||
@@ -23,6 +25,8 @@ type TagUnassignment struct {
|
||||
Tags []string `json:"tags"`
|
||||
}
|
||||
|
||||
type _TagUnassignment TagUnassignment
|
||||
|
||||
// NewTagUnassignment instantiates a new TagUnassignment object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
@@ -105,6 +109,44 @@ func (o TagUnassignment) ToMap() (map[string]interface{}, error) {
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
func (o *TagUnassignment) UnmarshalJSON(data []byte) (err error) {
|
||||
// This validates that all required properties are included in the JSON object
|
||||
// by unmarshalling the object into a generic map with string keys and checking
|
||||
// that every required field exists as a key in the generic map.
|
||||
requiredProperties := []string{
|
||||
"resourceId",
|
||||
"tags",
|
||||
}
|
||||
|
||||
allProperties := make(map[string]interface{})
|
||||
|
||||
err = json.Unmarshal(data, &allProperties)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, requiredProperty := range requiredProperties {
|
||||
if _, exists := allProperties[requiredProperty]; !exists {
|
||||
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
||||
}
|
||||
}
|
||||
|
||||
varTagUnassignment := _TagUnassignment{}
|
||||
|
||||
decoder := json.NewDecoder(bytes.NewReader(data))
|
||||
decoder.DisallowUnknownFields()
|
||||
err = decoder.Decode(&varTagUnassignment)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
*o = TagUnassignment(varTagUnassignment)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
type NullableTagUnassignment struct {
|
||||
value *TagUnassignment
|
||||
isSet bool
|
||||
|
||||
+1
-1
@@ -320,7 +320,7 @@ func NewNullableTime(val *time.Time) *NullableTime {
|
||||
}
|
||||
|
||||
func (v NullableTime) MarshalJSON() ([]byte, error) {
|
||||
return v.value.MarshalJSON()
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableTime) UnmarshalJSON(src []byte) error {
|
||||
|
||||
Reference in New Issue
Block a user