teamchannel

package
v0.20241029.1112340 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/microsoft-graph/groups/beta/teamchannel Documentation

The teamchannel SDK allows for interaction with Microsoft Graph groups (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/groups/beta/teamchannel"

Client Initialization

client := teamchannel.NewTeamChannelClientWithBaseURI("https://graph.microsoft.com")
client.Client.Authorizer = authorizer

Example Usage: TeamChannelClient.CreateTeamChannel

ctx := context.TODO()
id := teamchannel.NewGroupID("groupId")

payload := teamchannel.Channel{
	// ...
}


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

Example Usage: TeamChannelClient.CreateTeamChannelArchive

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

payload := teamchannel.CreateTeamChannelArchiveRequest{
	// ...
}


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

Example Usage: TeamChannelClient.CreateTeamChannelCompleteMigration

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.CreateTeamChannelUnarchive

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.DeleteTeamChannel

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.GetTeamChannel

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.GetTeamChannelsCount

ctx := context.TODO()
id := teamchannel.NewGroupID("groupId")

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

Example Usage: TeamChannelClient.ListTeamChannels

ctx := context.TODO()
id := teamchannel.NewGroupID("groupId")

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

Example Usage: TeamChannelClient.ProvisionTeamChannelEmail

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.RemoveTeamChannelEmail

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

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

Example Usage: TeamChannelClient.UpdateTeamChannel

ctx := context.TODO()
id := teamchannel.NewGroupIdTeamChannelID("groupId", "channelId")

payload := teamchannel.Channel{
	// ...
}


read, err := client.UpdateTeamChannel(ctx, id, payload, teamchannel.DefaultUpdateTeamChannelOperationOptions())
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 ChannelOperationPredicate

type ChannelOperationPredicate struct {
}

func (ChannelOperationPredicate) Matches

func (p ChannelOperationPredicate) Matches(input beta.Channel) bool

type CreateTeamChannelArchiveOperationOptions

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

func DefaultCreateTeamChannelArchiveOperationOptions

func DefaultCreateTeamChannelArchiveOperationOptions() CreateTeamChannelArchiveOperationOptions

func (CreateTeamChannelArchiveOperationOptions) ToHeaders

func (CreateTeamChannelArchiveOperationOptions) ToOData

func (CreateTeamChannelArchiveOperationOptions) ToQuery

type CreateTeamChannelArchiveOperationResponse

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

type CreateTeamChannelArchiveRequest

type CreateTeamChannelArchiveRequest struct {
	ShouldSetSpoSiteReadOnlyForMembers nullable.Type[bool] `json:"shouldSetSpoSiteReadOnlyForMembers,omitempty"`
}

type CreateTeamChannelCompleteMigrationOperationOptions

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

func DefaultCreateTeamChannelCompleteMigrationOperationOptions

func DefaultCreateTeamChannelCompleteMigrationOperationOptions() CreateTeamChannelCompleteMigrationOperationOptions

func (CreateTeamChannelCompleteMigrationOperationOptions) ToHeaders

func (CreateTeamChannelCompleteMigrationOperationOptions) ToOData

func (CreateTeamChannelCompleteMigrationOperationOptions) ToQuery

type CreateTeamChannelCompleteMigrationOperationResponse

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

type CreateTeamChannelOperationOptions

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

func DefaultCreateTeamChannelOperationOptions

func DefaultCreateTeamChannelOperationOptions() CreateTeamChannelOperationOptions

func (CreateTeamChannelOperationOptions) ToHeaders

func (CreateTeamChannelOperationOptions) ToOData

func (CreateTeamChannelOperationOptions) ToQuery

type CreateTeamChannelOperationResponse

type CreateTeamChannelOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Channel
}

type CreateTeamChannelUnarchiveOperationOptions

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

func DefaultCreateTeamChannelUnarchiveOperationOptions

func DefaultCreateTeamChannelUnarchiveOperationOptions() CreateTeamChannelUnarchiveOperationOptions

func (CreateTeamChannelUnarchiveOperationOptions) ToHeaders

func (CreateTeamChannelUnarchiveOperationOptions) ToOData

func (CreateTeamChannelUnarchiveOperationOptions) ToQuery

type CreateTeamChannelUnarchiveOperationResponse

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

type DeleteTeamChannelOperationOptions

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

func DefaultDeleteTeamChannelOperationOptions

func DefaultDeleteTeamChannelOperationOptions() DeleteTeamChannelOperationOptions

func (DeleteTeamChannelOperationOptions) ToHeaders

func (DeleteTeamChannelOperationOptions) ToOData

func (DeleteTeamChannelOperationOptions) ToQuery

type DeleteTeamChannelOperationResponse

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

type GetTeamChannelOperationOptions

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

func DefaultGetTeamChannelOperationOptions

func DefaultGetTeamChannelOperationOptions() GetTeamChannelOperationOptions

func (GetTeamChannelOperationOptions) ToHeaders

func (GetTeamChannelOperationOptions) ToOData

func (GetTeamChannelOperationOptions) ToQuery

type GetTeamChannelOperationResponse

type GetTeamChannelOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Channel
}

type GetTeamChannelsCountOperationOptions

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

func DefaultGetTeamChannelsCountOperationOptions

func DefaultGetTeamChannelsCountOperationOptions() GetTeamChannelsCountOperationOptions

func (GetTeamChannelsCountOperationOptions) ToHeaders

func (GetTeamChannelsCountOperationOptions) ToOData

func (GetTeamChannelsCountOperationOptions) ToQuery

type GetTeamChannelsCountOperationResponse

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

type ListTeamChannelsCompleteResult

type ListTeamChannelsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.Channel
}

type ListTeamChannelsCustomPager

type ListTeamChannelsCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}
func (p *ListTeamChannelsCustomPager) NextPageLink() *odata.Link

type ListTeamChannelsOperationOptions

type ListTeamChannelsOperationOptions 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 DefaultListTeamChannelsOperationOptions

func DefaultListTeamChannelsOperationOptions() ListTeamChannelsOperationOptions

func (ListTeamChannelsOperationOptions) ToHeaders

func (ListTeamChannelsOperationOptions) ToOData

func (ListTeamChannelsOperationOptions) ToQuery

type ListTeamChannelsOperationResponse

type ListTeamChannelsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.Channel
}

type ProvisionTeamChannelEmailOperationOptions

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

func DefaultProvisionTeamChannelEmailOperationOptions

func DefaultProvisionTeamChannelEmailOperationOptions() ProvisionTeamChannelEmailOperationOptions

func (ProvisionTeamChannelEmailOperationOptions) ToHeaders

func (ProvisionTeamChannelEmailOperationOptions) ToOData

func (ProvisionTeamChannelEmailOperationOptions) ToQuery

type ProvisionTeamChannelEmailOperationResponse

type ProvisionTeamChannelEmailOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.ProvisionChannelEmailResult
}

type RemoveTeamChannelEmailOperationOptions

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

func DefaultRemoveTeamChannelEmailOperationOptions

func DefaultRemoveTeamChannelEmailOperationOptions() RemoveTeamChannelEmailOperationOptions

func (RemoveTeamChannelEmailOperationOptions) ToHeaders

func (RemoveTeamChannelEmailOperationOptions) ToOData

func (RemoveTeamChannelEmailOperationOptions) ToQuery

type RemoveTeamChannelEmailOperationResponse

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

type TeamChannelClient

type TeamChannelClient struct {
	Client *msgraph.Client
}

func NewTeamChannelClientWithBaseURI

func NewTeamChannelClientWithBaseURI(sdkApi sdkEnv.Api) (*TeamChannelClient, error)

func (TeamChannelClient) CreateTeamChannel

CreateTeamChannel - Create new navigation property to channels for groups

func (TeamChannelClient) CreateTeamChannelArchive

CreateTeamChannelArchive - Invoke action archive. Archive a channel in a team. When a channel is archived, users can't send new messages or react to existing messages in the channel, edit the channel settings, or make other changes to the channel. You can delete an archived channel or add and remove members from it. If you archive a team, its channels are also archived. Archiving is an asynchronous operation; a channel is archived after the asynchronous archiving operation completes successfully, which might occur after the response returns. A channel without an owner or that belongs to a group that has no owner, can't be archived. To restore a channel from its archived state, use the channel: unarchive method. A channel can’t be archived or unarchived if its team is archived.

func (TeamChannelClient) CreateTeamChannelCompleteMigration

CreateTeamChannelCompleteMigration - Invoke action completeMigration. Complete the message migration process by removing migration mode from a channel in a team. Migration mode is a special state that prevents certain operations, like sending messages and adding members, during the data migration process. After a completeMigration request is made, you can't import more messages into the team. You can add members to the team after the request returns a successful response.

func (TeamChannelClient) CreateTeamChannelUnarchive

CreateTeamChannelUnarchive - Invoke action unarchive. Restore an archived channel. Unarchiving restores the ability for users to send messages and edit the channel. Channels are archived via the channel: archive method. Unarchiving is an asynchronous operation; a channel is unarchived when the asynchronous unarchiving operation completes successfully, which might occur after this method responds.

func (TeamChannelClient) DeleteTeamChannel

DeleteTeamChannel - Delete navigation property channels for groups

func (TeamChannelClient) GetTeamChannel

GetTeamChannel - Get channels from groups. The collection of channels and messages associated with the team.

func (TeamChannelClient) GetTeamChannelsCount

GetTeamChannelsCount - Get the number of the resource

func (TeamChannelClient) ListTeamChannels

ListTeamChannels - Get channels from groups. The collection of channels and messages associated with the team.

func (TeamChannelClient) ListTeamChannelsComplete

ListTeamChannelsComplete retrieves all the results into a single object

func (TeamChannelClient) ListTeamChannelsCompleteMatchingPredicate

func (c TeamChannelClient) ListTeamChannelsCompleteMatchingPredicate(ctx context.Context, id beta.GroupId, options ListTeamChannelsOperationOptions, predicate ChannelOperationPredicate) (result ListTeamChannelsCompleteResult, err error)

ListTeamChannelsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (TeamChannelClient) ProvisionTeamChannelEmail

ProvisionTeamChannelEmail - Invoke action provisionEmail. Provision an email address for a channel. Microsoft Teams doesn't automatically provision an email address for a channel by default. To have Teams provision an email address, you can call provisionEmail, or through the Teams user interface, select Get email address, which triggers Teams to generate an email address if it didn't provisioned one. To remove the email address of a channel, use the removeEmail method.

func (TeamChannelClient) RemoveTeamChannelEmail

RemoveTeamChannelEmail - Invoke action removeEmail. Remove the email address of a channel. You can remove an email address only if it was provisioned using the provisionEmail method or through the Microsoft Teams client.

func (TeamChannelClient) UpdateTeamChannel

UpdateTeamChannel - Update the navigation property channels in groups

type UpdateTeamChannelOperationOptions

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

func DefaultUpdateTeamChannelOperationOptions

func DefaultUpdateTeamChannelOperationOptions() UpdateTeamChannelOperationOptions

func (UpdateTeamChannelOperationOptions) ToHeaders

func (UpdateTeamChannelOperationOptions) ToOData

func (UpdateTeamChannelOperationOptions) ToQuery

type UpdateTeamChannelOperationResponse

type UpdateTeamChannelOperationResponse 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