Skip to content

Latest commit

 

History

History
192 lines (121 loc) · 4.58 KB

MeDriveApi.md

File metadata and controls

192 lines (121 loc) · 4.58 KB

\MeDriveApi

All URIs are relative to https://ocis.ocis.rolling.owncloud.works/graph

Method HTTP request Description
GetHome Get /v1.0/me/drive Get personal space for user
ListSharedByMe Get /v1beta1/me/drive/sharedByMe Get a list of driveItem objects shared by the current user.
ListSharedWithMe Get /v1beta1/me/drive/sharedWithMe Get a list of driveItem objects shared with the owner of a drive.

GetHome

Drive GetHome(ctx).Execute()

Get personal space for user

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/owncloud/libre-graph-api-go"
)

func main() {

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.MeDriveApi.GetHome(context.Background()).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `MeDriveApi.GetHome``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetHome`: Drive
	fmt.Fprintf(os.Stdout, "Response from `MeDriveApi.GetHome`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiGetHomeRequest struct via the builder pattern

Return type

Drive

Authorization

openId, basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ListSharedByMe

CollectionOfDriveItems1 ListSharedByMe(ctx).Execute()

Get a list of driveItem objects shared by the current user.

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/owncloud/libre-graph-api-go"
)

func main() {

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.MeDriveApi.ListSharedByMe(context.Background()).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `MeDriveApi.ListSharedByMe``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListSharedByMe`: CollectionOfDriveItems1
	fmt.Fprintf(os.Stdout, "Response from `MeDriveApi.ListSharedByMe`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiListSharedByMeRequest struct via the builder pattern

Return type

CollectionOfDriveItems1

Authorization

openId, basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ListSharedWithMe

CollectionOfDriveItems1 ListSharedWithMe(ctx).Execute()

Get a list of driveItem objects shared with the owner of a drive.

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/owncloud/libre-graph-api-go"
)

func main() {

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.MeDriveApi.ListSharedWithMe(context.Background()).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `MeDriveApi.ListSharedWithMe``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListSharedWithMe`: CollectionOfDriveItems1
	fmt.Fprintf(os.Stdout, "Response from `MeDriveApi.ListSharedWithMe`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiListSharedWithMeRequest struct via the builder pattern

Return type

CollectionOfDriveItems1

Authorization

openId, basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]