Skip to content

Latest commit

 

History

History
56 lines (48 loc) · 1.75 KB

File metadata and controls

56 lines (48 loc) · 1.75 KB
description Automatically generated file. DO NOT MODIFY
// Code snippets are only available for the latest major version. Current major version is $v0.*

// Dependencies
import (
	  "context"
	  msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
	  graphcommunications "github.com/microsoftgraph/msgraph-beta-sdk-go/communications"
	  graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
	  //other-imports
)

requestBody := graphcommunications.NewSendDtmfTonesPostRequestBody()
tones := []graphmodels.Toneable {
	tone := graphmodels.TONE1_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE2_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE3_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE4_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE5_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE6_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE7_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE8_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE9_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.TONE0_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.STAR_TONE 
	requestBody.SetTone(&tone) 
	tone := graphmodels.POUND_TONE 
	requestBody.SetTone(&tone)
}
requestBody.SetTones(tones)
delayBetweenTonesMs := int32(1000)
requestBody.SetDelayBetweenTonesMs(&delayBetweenTonesMs) 
clientContext := "e0be71f1-a14f-4cec-b65a-e7aba5db7c53"
requestBody.SetClientContext(&clientContext) 

// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
sendDtmfTones, err := graphClient.Communications().Calls().ByCallId("call-id").SendDtmfTones().Post(context.Background(), requestBody, nil)