drivelistitempermission

package
v0.20241009.1142232 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2024 License: MPL-2.0 Imports: 8 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/microsoft-graph/users/beta/drivelistitempermission Documentation

The drivelistitempermission SDK allows for interaction with Microsoft Graph users (API Version beta).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/microsoft-graph/users/beta/drivelistitempermission"

Client Initialization

client := drivelistitempermission.NewDriveListItemPermissionClientWithBaseURI("https://graph.microsoft.com")
client.Client.Authorizer = authorizer

Example Usage: DriveListItemPermissionClient.CreateDriveListItemPermission

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemID("userId", "driveId", "listItemId")

payload := drivelistitempermission.Permission{
	// ...
}


read, err := client.CreateDriveListItemPermission(ctx, id, payload, drivelistitempermission.DefaultCreateDriveListItemPermissionOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: DriveListItemPermissionClient.DeleteDriveListItemPermission

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemIdPermissionID("userId", "driveId", "listItemId", "permissionId")

read, err := client.DeleteDriveListItemPermission(ctx, id, drivelistitempermission.DefaultDeleteDriveListItemPermissionOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: DriveListItemPermissionClient.GetDriveListItemPermission

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemIdPermissionID("userId", "driveId", "listItemId", "permissionId")

read, err := client.GetDriveListItemPermission(ctx, id, drivelistitempermission.DefaultGetDriveListItemPermissionOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: DriveListItemPermissionClient.GetDriveListItemPermissionsCount

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemID("userId", "driveId", "listItemId")

read, err := client.GetDriveListItemPermissionsCount(ctx, id, drivelistitempermission.DefaultGetDriveListItemPermissionsCountOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: DriveListItemPermissionClient.ListDriveListItemPermissionGrants

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemIdPermissionID("userId", "driveId", "listItemId", "permissionId")

payload := drivelistitempermission.ListDriveListItemPermissionGrantsRequest{
	// ...
}


// alternatively `client.ListDriveListItemPermissionGrants(ctx, id, payload, drivelistitempermission.DefaultListDriveListItemPermissionGrantsOperationOptions())` can be used to do batched pagination
items, err := client.ListDriveListItemPermissionGrantsComplete(ctx, id, payload, drivelistitempermission.DefaultListDriveListItemPermissionGrantsOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: DriveListItemPermissionClient.ListDriveListItemPermissions

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemID("userId", "driveId", "listItemId")

// alternatively `client.ListDriveListItemPermissions(ctx, id, drivelistitempermission.DefaultListDriveListItemPermissionsOperationOptions())` can be used to do batched pagination
items, err := client.ListDriveListItemPermissionsComplete(ctx, id, drivelistitempermission.DefaultListDriveListItemPermissionsOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: DriveListItemPermissionClient.RevokeDriveListItemPermissionGrants

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemIdPermissionID("userId", "driveId", "listItemId", "permissionId")

payload := drivelistitempermission.RevokeDriveListItemPermissionGrantsRequest{
	// ...
}


read, err := client.RevokeDriveListItemPermissionGrants(ctx, id, payload, drivelistitempermission.DefaultRevokeDriveListItemPermissionGrantsOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: DriveListItemPermissionClient.UpdateDriveListItemPermission

ctx := context.TODO()
id := drivelistitempermission.NewUserIdDriveIdListItemIdPermissionID("userId", "driveId", "listItemId", "permissionId")

payload := drivelistitempermission.Permission{
	// ...
}


read, err := client.UpdateDriveListItemPermission(ctx, id, payload, drivelistitempermission.DefaultUpdateDriveListItemPermissionOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateDriveListItemPermissionOperationOptions

type CreateDriveListItemPermissionOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultCreateDriveListItemPermissionOperationOptions

func DefaultCreateDriveListItemPermissionOperationOptions() CreateDriveListItemPermissionOperationOptions

func (CreateDriveListItemPermissionOperationOptions) ToHeaders

func (CreateDriveListItemPermissionOperationOptions) ToOData

func (CreateDriveListItemPermissionOperationOptions) ToQuery

type CreateDriveListItemPermissionOperationResponse

type CreateDriveListItemPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type DeleteDriveListItemPermissionOperationOptions

type DeleteDriveListItemPermissionOperationOptions struct {
	IfMatch   *string
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultDeleteDriveListItemPermissionOperationOptions

func DefaultDeleteDriveListItemPermissionOperationOptions() DeleteDriveListItemPermissionOperationOptions

func (DeleteDriveListItemPermissionOperationOptions) ToHeaders

func (DeleteDriveListItemPermissionOperationOptions) ToOData

func (DeleteDriveListItemPermissionOperationOptions) ToQuery

type DeleteDriveListItemPermissionOperationResponse

type DeleteDriveListItemPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

type DriveListItemPermissionClient

type DriveListItemPermissionClient struct {
	Client *msgraph.Client
}

func NewDriveListItemPermissionClientWithBaseURI

func NewDriveListItemPermissionClientWithBaseURI(sdkApi sdkEnv.Api) (*DriveListItemPermissionClient, error)

func (DriveListItemPermissionClient) CreateDriveListItemPermission

CreateDriveListItemPermission - Create new navigation property to permissions for users

func (DriveListItemPermissionClient) DeleteDriveListItemPermission

DeleteDriveListItemPermission - Delete navigation property permissions for users

func (DriveListItemPermissionClient) GetDriveListItemPermission

GetDriveListItemPermission - Get permissions from users. The set of permissions for the item. Read-only. Nullable.

func (DriveListItemPermissionClient) GetDriveListItemPermissionsCount

GetDriveListItemPermissionsCount - Get the number of the resource

func (DriveListItemPermissionClient) ListDriveListItemPermissionGrants

ListDriveListItemPermissionGrants - Invoke action grant. Grant users access to a link represented by a permission.

func (DriveListItemPermissionClient) ListDriveListItemPermissionGrantsComplete

ListDriveListItemPermissionGrantsComplete retrieves all the results into a single object

func (DriveListItemPermissionClient) ListDriveListItemPermissionGrantsCompleteMatchingPredicate

ListDriveListItemPermissionGrantsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (DriveListItemPermissionClient) ListDriveListItemPermissions

ListDriveListItemPermissions - Get permissions from users. The set of permissions for the item. Read-only. Nullable.

func (DriveListItemPermissionClient) ListDriveListItemPermissionsComplete

ListDriveListItemPermissionsComplete retrieves all the results into a single object

func (DriveListItemPermissionClient) ListDriveListItemPermissionsCompleteMatchingPredicate

ListDriveListItemPermissionsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (DriveListItemPermissionClient) RevokeDriveListItemPermissionGrants

RevokeDriveListItemPermissionGrants - Invoke action revokeGrants. Revoke access to a listItem or driveItem granted via a sharing link by removing the specified recipient from the link.

func (DriveListItemPermissionClient) UpdateDriveListItemPermission

UpdateDriveListItemPermission - Update the navigation property permissions in users

type GetDriveListItemPermissionOperationOptions

type GetDriveListItemPermissionOperationOptions struct {
	Expand    *odata.Expand
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Select    *[]string
}

func DefaultGetDriveListItemPermissionOperationOptions

func DefaultGetDriveListItemPermissionOperationOptions() GetDriveListItemPermissionOperationOptions

func (GetDriveListItemPermissionOperationOptions) ToHeaders

func (GetDriveListItemPermissionOperationOptions) ToOData

func (GetDriveListItemPermissionOperationOptions) ToQuery

type GetDriveListItemPermissionOperationResponse

type GetDriveListItemPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type GetDriveListItemPermissionsCountOperationOptions

type GetDriveListItemPermissionsCountOperationOptions struct {
	Filter    *string
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Search    *string
}

func DefaultGetDriveListItemPermissionsCountOperationOptions

func DefaultGetDriveListItemPermissionsCountOperationOptions() GetDriveListItemPermissionsCountOperationOptions

func (GetDriveListItemPermissionsCountOperationOptions) ToHeaders

func (GetDriveListItemPermissionsCountOperationOptions) ToOData

func (GetDriveListItemPermissionsCountOperationOptions) ToQuery

type GetDriveListItemPermissionsCountOperationResponse

type GetDriveListItemPermissionsCountOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]byte
}

type ListDriveListItemPermissionGrantsCompleteResult

type ListDriveListItemPermissionGrantsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.Permission
}

type ListDriveListItemPermissionGrantsCustomPager

type ListDriveListItemPermissionGrantsCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}

type ListDriveListItemPermissionGrantsOperationOptions

type ListDriveListItemPermissionGrantsOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Skip      *int64
	Top       *int64
}

func DefaultListDriveListItemPermissionGrantsOperationOptions

func DefaultListDriveListItemPermissionGrantsOperationOptions() ListDriveListItemPermissionGrantsOperationOptions

func (ListDriveListItemPermissionGrantsOperationOptions) ToHeaders

func (ListDriveListItemPermissionGrantsOperationOptions) ToOData

func (ListDriveListItemPermissionGrantsOperationOptions) ToQuery

type ListDriveListItemPermissionGrantsOperationResponse

type ListDriveListItemPermissionGrantsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.Permission
}

type ListDriveListItemPermissionGrantsRequest

type ListDriveListItemPermissionGrantsRequest struct {
	Recipients *[]beta.DriveRecipient `json:"recipients,omitempty"`
	Roles      *[]string              `json:"roles,omitempty"`
}

type ListDriveListItemPermissionsCompleteResult

type ListDriveListItemPermissionsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.Permission
}

type ListDriveListItemPermissionsCustomPager

type ListDriveListItemPermissionsCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}

type ListDriveListItemPermissionsOperationOptions

type ListDriveListItemPermissionsOperationOptions struct {
	Count     *bool
	Expand    *odata.Expand
	Filter    *string
	Metadata  *odata.Metadata
	OrderBy   *odata.OrderBy
	RetryFunc client.RequestRetryFunc
	Search    *string
	Select    *[]string
	Skip      *int64
	Top       *int64
}

func DefaultListDriveListItemPermissionsOperationOptions

func DefaultListDriveListItemPermissionsOperationOptions() ListDriveListItemPermissionsOperationOptions

func (ListDriveListItemPermissionsOperationOptions) ToHeaders

func (ListDriveListItemPermissionsOperationOptions) ToOData

func (ListDriveListItemPermissionsOperationOptions) ToQuery

type ListDriveListItemPermissionsOperationResponse

type ListDriveListItemPermissionsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.Permission
}

type PermissionOperationPredicate

type PermissionOperationPredicate struct {
}

func (PermissionOperationPredicate) Matches

type RevokeDriveListItemPermissionGrantsOperationOptions

type RevokeDriveListItemPermissionGrantsOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultRevokeDriveListItemPermissionGrantsOperationOptions

func DefaultRevokeDriveListItemPermissionGrantsOperationOptions() RevokeDriveListItemPermissionGrantsOperationOptions

func (RevokeDriveListItemPermissionGrantsOperationOptions) ToHeaders

func (RevokeDriveListItemPermissionGrantsOperationOptions) ToOData

func (RevokeDriveListItemPermissionGrantsOperationOptions) ToQuery

type RevokeDriveListItemPermissionGrantsOperationResponse

type RevokeDriveListItemPermissionGrantsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type RevokeDriveListItemPermissionGrantsRequest

type RevokeDriveListItemPermissionGrantsRequest struct {
	Grantees *[]beta.DriveRecipient `json:"grantees,omitempty"`
}

type UpdateDriveListItemPermissionOperationOptions

type UpdateDriveListItemPermissionOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultUpdateDriveListItemPermissionOperationOptions

func DefaultUpdateDriveListItemPermissionOperationOptions() UpdateDriveListItemPermissionOperationOptions

func (UpdateDriveListItemPermissionOperationOptions) ToHeaders

func (UpdateDriveListItemPermissionOperationOptions) ToOData

func (UpdateDriveListItemPermissionOperationOptions) ToQuery

type UpdateDriveListItemPermissionOperationResponse

type UpdateDriveListItemPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL