PATCH https://graph.microsoft.com/v1.0/solutions/bookingBusinesses/Contosolunchdelivery@contoso.com/appointments/AAMkADKnAAA=
Content-type: application/json
{
"@odata.type":"#microsoft.graph.bookingAppointment",
"end":{
"@odata.type":"#microsoft.graph.dateTimeTimeZone",
"dateTime":"2018-05-06T12:30:00.0000000+00:00",
"timeZone":"UTC"
},
"start":{
"@odata.type":"#microsoft.graph.dateTimeTimeZone",
"dateTime":"2018-05-06T12:00:00.0000000+00:00",
"timeZone":"UTC"
}
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new BookingAppointment
{
OdataType = "#microsoft.graph.bookingAppointment",
AdditionalData = new Dictionary<string, object>
{
{
"end" , new DateTimeTimeZone
{
OdataType = "#microsoft.graph.dateTimeTimeZone",
DateTime = "2018-05-06T12:30:00.0000000+00:00",
TimeZone = "UTC",
}
},
{
"start" , new DateTimeTimeZone
{
OdataType = "#microsoft.graph.dateTimeTimeZone",
DateTime = "2018-05-06T12:00:00.0000000+00:00",
TimeZone = "UTC",
}
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Solutions.BookingBusinesses["{bookingBusiness-id}"].Appointments["{bookingAppointment-id}"].PatchAsync(requestBody);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
// Code snippets are only available for the latest major version. Current major version is $v1.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewBookingAppointment()
additionalData := map[string]interface{}{
end := graphmodels.NewDateTimeTimeZone()
dateTime := "2018-05-06T12:30:00.0000000+00:00"
end.SetDateTime(&dateTime)
timeZone := "UTC"
end.SetTimeZone(&timeZone)
requestBody.SetEnd(end)
start := graphmodels.NewDateTimeTimeZone()
dateTime := "2018-05-06T12:00:00.0000000+00:00"
start.SetDateTime(&dateTime)
timeZone := "UTC"
start.SetTimeZone(&timeZone)
requestBody.SetStart(start)
}
requestBody.SetAdditionalData(additionalData)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
appointments, err := graphClient.Solutions().BookingBusinesses().ByBookingBusinessId("bookingBusiness-id").Appointments().ByBookingAppointmentId("bookingAppointment-id").Patch(context.Background(), requestBody, nil)
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
BookingAppointment bookingAppointment = new BookingAppointment();
bookingAppointment.setOdataType("#microsoft.graph.bookingAppointment");
HashMap<String, Object> additionalData = new HashMap<String, Object>();
DateTimeTimeZone end = new DateTimeTimeZone();
end.setOdataType("#microsoft.graph.dateTimeTimeZone");
end.setDateTime("2018-05-06T12:30:00.0000000+00:00");
end.setTimeZone("UTC");
additionalData.put("end", end);
DateTimeTimeZone start = new DateTimeTimeZone();
start.setOdataType("#microsoft.graph.dateTimeTimeZone");
start.setDateTime("2018-05-06T12:00:00.0000000+00:00");
start.setTimeZone("UTC");
additionalData.put("start", start);
bookingAppointment.setAdditionalData(additionalData);
BookingAppointment result = graphClient.solutions().bookingBusinesses().byBookingBusinessId("{bookingBusiness-id}").appointments().byBookingAppointmentId("{bookingAppointment-id}").patch(bookingAppointment);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
const options = {
authProvider,
};
const client = Client.init(options);
const bookingAppointment = {
'@odata.type':'#microsoft.graph.bookingAppointment',
end: {
'@odata.type':'#microsoft.graph.dateTimeTimeZone',
dateTime: '2018-05-06T12:30:00.0000000+00:00',
timeZone: 'UTC'
},
start: {
'@odata.type':'#microsoft.graph.dateTimeTimeZone',
dateTime: '2018-05-06T12:00:00.0000000+00:00',
timeZone: 'UTC'
}
};
await client.api('/solutions/bookingBusinesses/Contosolunchdelivery@contoso.com/appointments/AAMkADKnAAA=')
.update(bookingAppointment);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
<?php
use Microsoft\Graph\GraphServiceClient;
use Microsoft\Graph\Generated\Models\BookingAppointment;
use Microsoft\Graph\Generated\Models\DateTimeTimeZone;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new BookingAppointment();
$requestBody->setOdataType('#microsoft.graph.bookingAppointment');
$additionalData = [
'end' => [
'@odata.type' => '#microsoft.graph.dateTimeTimeZone',
'dateTime' => '2018-05-06T12:30:00.0000000+00:00',
'timeZone' => 'UTC',
],
'start' => [
'@odata.type' => '#microsoft.graph.dateTimeTimeZone',
'dateTime' => '2018-05-06T12:00:00.0000000+00:00',
'timeZone' => 'UTC',
],
];
$requestBody->setAdditionalData($additionalData);
$result = $graphServiceClient->solutions()->bookingBusinesses()->byBookingBusinessId('bookingBusiness-id')->appointments()->byBookingAppointmentId('bookingAppointment-id')->patch($requestBody)->wait();
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
Import-Module Microsoft.Graph.Bookings
$params = @{
"@odata.type" = "#microsoft.graph.bookingAppointment"
end = @{
"@odata.type" = "#microsoft.graph.dateTimeTimeZone"
dateTime = "2018-05-06T12:30:00.0000000+00:00"
timeZone = "UTC"
}
start = @{
"@odata.type" = "#microsoft.graph.dateTimeTimeZone"
dateTime = "2018-05-06T12:00:00.0000000+00:00"
timeZone = "UTC"
}
}
Update-MgBookingBusinessAppointment -BookingBusinessId $bookingBusinessId -BookingAppointmentId $bookingAppointmentId -BodyParameter $params
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.booking_appointment import BookingAppointment
from msgraph.generated.models.date_time_time_zone import DateTimeTimeZone
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = BookingAppointment(
odata_type = "#microsoft.graph.bookingAppointment",
additional_data = {
"end" : {
"@odata_type" : "#microsoft.graph.dateTimeTimeZone",
"date_time" : "2018-05-06T12:30:00.0000000+00:00",
"time_zone" : "UTC",
},
"start" : {
"@odata_type" : "#microsoft.graph.dateTimeTimeZone",
"date_time" : "2018-05-06T12:00:00.0000000+00:00",
"time_zone" : "UTC",
},
}
)
result = await graph_client.solutions.booking_businesses.by_booking_business_id('bookingBusiness-id').appointments.by_booking_appointment_id('bookingAppointment-id').patch(request_body)
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
PATCH https://graph.microsoft.com/v1.0/solutions/bookingBusinesses/Contosolunchdelivery@contoso.com/appointments/AAMkADKoAAA=
Content-type: application/json
{
"@odata.type":"#microsoft.graph.bookingAppointment",
"customers": [
{
"@odata.type": "#microsoft.graph.bookingCustomerInformation",
"customerId": "cd56bb19-c348-42c6-af5c-09818c87fb8c",
"name": "John Doe",
"emailAddress": "john.doe@example.com",
"phone": "313-555-5555"
},
{
"@odata.type": "#microsoft.graph.bookingCustomerInformation",
"customerId": "72f148fa-9a86-4c59-b277-f5089d9ea0e7",
"name": "Jane Smith",
"emailAddress": "jane.smith@example.com",
"phone": "248-555-5678"
}
]
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new BookingAppointment
{
OdataType = "#microsoft.graph.bookingAppointment",
Customers = new List<BookingCustomerInformationBase>
{
new BookingCustomerInformation
{
OdataType = "#microsoft.graph.bookingCustomerInformation",
CustomerId = "cd56bb19-c348-42c6-af5c-09818c87fb8c",
Name = "John Doe",
EmailAddress = "john.doe@example.com",
Phone = "313-555-5555",
},
new BookingCustomerInformation
{
OdataType = "#microsoft.graph.bookingCustomerInformation",
CustomerId = "72f148fa-9a86-4c59-b277-f5089d9ea0e7",
Name = "Jane Smith",
EmailAddress = "jane.smith@example.com",
Phone = "248-555-5678",
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Solutions.BookingBusinesses["{bookingBusiness-id}"].Appointments["{bookingAppointment-id}"].PatchAsync(requestBody);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
// Code snippets are only available for the latest major version. Current major version is $v1.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewBookingAppointment()
bookingCustomerInformationBase := graphmodels.NewBookingCustomerInformation()
customerId := "cd56bb19-c348-42c6-af5c-09818c87fb8c"
bookingCustomerInformationBase.SetCustomerId(&customerId)
name := "John Doe"
bookingCustomerInformationBase.SetName(&name)
emailAddress := "john.doe@example.com"
bookingCustomerInformationBase.SetEmailAddress(&emailAddress)
phone := "313-555-5555"
bookingCustomerInformationBase.SetPhone(&phone)
bookingCustomerInformationBase1 := graphmodels.NewBookingCustomerInformation()
customerId := "72f148fa-9a86-4c59-b277-f5089d9ea0e7"
bookingCustomerInformationBase1.SetCustomerId(&customerId)
name := "Jane Smith"
bookingCustomerInformationBase1.SetName(&name)
emailAddress := "jane.smith@example.com"
bookingCustomerInformationBase1.SetEmailAddress(&emailAddress)
phone := "248-555-5678"
bookingCustomerInformationBase1.SetPhone(&phone)
customers := []graphmodels.BookingCustomerInformationBaseable {
bookingCustomerInformationBase,
bookingCustomerInformationBase1,
}
requestBody.SetCustomers(customers)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
appointments, err := graphClient.Solutions().BookingBusinesses().ByBookingBusinessId("bookingBusiness-id").Appointments().ByBookingAppointmentId("bookingAppointment-id").Patch(context.Background(), requestBody, nil)
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
BookingAppointment bookingAppointment = new BookingAppointment();
bookingAppointment.setOdataType("#microsoft.graph.bookingAppointment");
LinkedList<BookingCustomerInformationBase> customers = new LinkedList<BookingCustomerInformationBase>();
BookingCustomerInformation bookingCustomerInformationBase = new BookingCustomerInformation();
bookingCustomerInformationBase.setOdataType("#microsoft.graph.bookingCustomerInformation");
bookingCustomerInformationBase.setCustomerId("cd56bb19-c348-42c6-af5c-09818c87fb8c");
bookingCustomerInformationBase.setName("John Doe");
bookingCustomerInformationBase.setEmailAddress("john.doe@example.com");
bookingCustomerInformationBase.setPhone("313-555-5555");
customers.add(bookingCustomerInformationBase);
BookingCustomerInformation bookingCustomerInformationBase1 = new BookingCustomerInformation();
bookingCustomerInformationBase1.setOdataType("#microsoft.graph.bookingCustomerInformation");
bookingCustomerInformationBase1.setCustomerId("72f148fa-9a86-4c59-b277-f5089d9ea0e7");
bookingCustomerInformationBase1.setName("Jane Smith");
bookingCustomerInformationBase1.setEmailAddress("jane.smith@example.com");
bookingCustomerInformationBase1.setPhone("248-555-5678");
customers.add(bookingCustomerInformationBase1);
bookingAppointment.setCustomers(customers);
BookingAppointment result = graphClient.solutions().bookingBusinesses().byBookingBusinessId("{bookingBusiness-id}").appointments().byBookingAppointmentId("{bookingAppointment-id}").patch(bookingAppointment);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
const options = {
authProvider,
};
const client = Client.init(options);
const bookingAppointment = {
'@odata.type':'#microsoft.graph.bookingAppointment',
customers: [
{
'@odata.type': '#microsoft.graph.bookingCustomerInformation',
customerId: 'cd56bb19-c348-42c6-af5c-09818c87fb8c',
name: 'John Doe',
emailAddress: 'john.doe@example.com',
phone: '313-555-5555'
},
{
'@odata.type': '#microsoft.graph.bookingCustomerInformation',
customerId: '72f148fa-9a86-4c59-b277-f5089d9ea0e7',
name: 'Jane Smith',
emailAddress: 'jane.smith@example.com',
phone: '248-555-5678'
}
]
};
await client.api('/solutions/bookingBusinesses/Contosolunchdelivery@contoso.com/appointments/AAMkADKoAAA=')
.update(bookingAppointment);
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
<?php
use Microsoft\Graph\GraphServiceClient;
use Microsoft\Graph\Generated\Models\BookingAppointment;
use Microsoft\Graph\Generated\Models\BookingCustomerInformationBase;
use Microsoft\Graph\Generated\Models\BookingCustomerInformation;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new BookingAppointment();
$requestBody->setOdataType('#microsoft.graph.bookingAppointment');
$customersBookingCustomerInformationBase1 = new BookingCustomerInformation();
$customersBookingCustomerInformationBase1->setOdataType('#microsoft.graph.bookingCustomerInformation');
$customersBookingCustomerInformationBase1->setCustomerId('cd56bb19-c348-42c6-af5c-09818c87fb8c');
$customersBookingCustomerInformationBase1->setName('John Doe');
$customersBookingCustomerInformationBase1->setEmailAddress('john.doe@example.com');
$customersBookingCustomerInformationBase1->setPhone('313-555-5555');
$customersArray []= $customersBookingCustomerInformationBase1;
$customersBookingCustomerInformationBase2 = new BookingCustomerInformation();
$customersBookingCustomerInformationBase2->setOdataType('#microsoft.graph.bookingCustomerInformation');
$customersBookingCustomerInformationBase2->setCustomerId('72f148fa-9a86-4c59-b277-f5089d9ea0e7');
$customersBookingCustomerInformationBase2->setName('Jane Smith');
$customersBookingCustomerInformationBase2->setEmailAddress('jane.smith@example.com');
$customersBookingCustomerInformationBase2->setPhone('248-555-5678');
$customersArray []= $customersBookingCustomerInformationBase2;
$requestBody->setCustomers($customersArray);
$result = $graphServiceClient->solutions()->bookingBusinesses()->byBookingBusinessId('bookingBusiness-id')->appointments()->byBookingAppointmentId('bookingAppointment-id')->patch($requestBody)->wait();
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
Import-Module Microsoft.Graph.Bookings
$params = @{
"@odata.type" = "#microsoft.graph.bookingAppointment"
customers = @(
@{
"@odata.type" = "#microsoft.graph.bookingCustomerInformation"
customerId = "cd56bb19-c348-42c6-af5c-09818c87fb8c"
name = "John Doe"
emailAddress = "john.doe@example.com"
phone = "313-555-5555"
}
@{
"@odata.type" = "#microsoft.graph.bookingCustomerInformation"
customerId = "72f148fa-9a86-4c59-b277-f5089d9ea0e7"
name = "Jane Smith"
emailAddress = "jane.smith@example.com"
phone = "248-555-5678"
}
)
}
Update-MgBookingBusinessAppointment -BookingBusinessId $bookingBusinessId -BookingAppointmentId $bookingAppointmentId -BodyParameter $params
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.booking_appointment import BookingAppointment
from msgraph.generated.models.booking_customer_information_base import BookingCustomerInformationBase
from msgraph.generated.models.booking_customer_information import BookingCustomerInformation
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = BookingAppointment(
odata_type = "#microsoft.graph.bookingAppointment",
customers = [
BookingCustomerInformation(
odata_type = "#microsoft.graph.bookingCustomerInformation",
customer_id = "cd56bb19-c348-42c6-af5c-09818c87fb8c",
name = "John Doe",
email_address = "john.doe@example.com",
phone = "313-555-5555",
),
BookingCustomerInformation(
odata_type = "#microsoft.graph.bookingCustomerInformation",
customer_id = "72f148fa-9a86-4c59-b277-f5089d9ea0e7",
name = "Jane Smith",
email_address = "jane.smith@example.com",
phone = "248-555-5678",
),
],
)
result = await graph_client.solutions.booking_businesses.by_booking_business_id('bookingBusiness-id').appointments.by_booking_appointment_id('bookingAppointment-id').patch(request_body)
プロジェクトに SDK を追加し、authProvider インスタンスを作成する方法の詳細については、SDK のドキュメントを参照してください。