PATCH https://graph.microsoft.com/beta/solutions/businessScenarios/c5d514e6c6864911ac46c720affb6e4d/planner/planConfiguration
Content-Type: application/json
{
"defaultLanguage": "en-us",
"buckets": [
{
"externalBucketId": "deliveryBucket"
},
{
"externalBucketId": "storePickupBucket"
},
{
"externalBucketId": "specialOrdersBucket"
},
{
"externalBucketId": "returnProcessingBucket"
}
],
"localizations": [
{
"id": "en-us",
"languageTag": "en-us",
"planTitle": "Order Tracking",
"buckets": [
{
"externalBucketId": "deliveryBucket",
"name": "Deliveries"
},
{
"externalBucketId": "storePickupBucket",
"name": "Pickup"
},
{
"externalBucketId": "specialOrdersBucket",
"name": "Special Orders"
},
{
"externalBucketId": "returnProcessingBucket",
"name": "Customer Returns"
}
]
},
{
"id": "es-es",
"languageTag": "es-es",
"planTitle": "Seguimiento de pedidos",
"buckets": [
{
"externalBucketId": "deliveryBucket",
"name": "Entregas"
},
{
"externalBucketId": "storePickupBucket",
"name": "Recogida"
},
{
"externalBucketId": "specialOrdersBucket",
"name": "Pedidos especiales"
},
{
"externalBucketId": "specialOrdersBucket",
"name": "Devoluciones de clientes"
}
]
}
]
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new PlannerPlanConfiguration
{
DefaultLanguage = "en-us",
Buckets = new List<PlannerPlanConfigurationBucketDefinition>
{
new PlannerPlanConfigurationBucketDefinition
{
ExternalBucketId = "deliveryBucket",
},
new PlannerPlanConfigurationBucketDefinition
{
ExternalBucketId = "storePickupBucket",
},
new PlannerPlanConfigurationBucketDefinition
{
ExternalBucketId = "specialOrdersBucket",
},
new PlannerPlanConfigurationBucketDefinition
{
ExternalBucketId = "returnProcessingBucket",
},
},
Localizations = new List<PlannerPlanConfigurationLocalization>
{
new PlannerPlanConfigurationLocalization
{
Id = "en-us",
LanguageTag = "en-us",
PlanTitle = "Order Tracking",
Buckets = new List<PlannerPlanConfigurationBucketLocalization>
{
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "deliveryBucket",
Name = "Deliveries",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "storePickupBucket",
Name = "Pickup",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "specialOrdersBucket",
Name = "Special Orders",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "returnProcessingBucket",
Name = "Customer Returns",
},
},
},
new PlannerPlanConfigurationLocalization
{
Id = "es-es",
LanguageTag = "es-es",
PlanTitle = "Seguimiento de pedidos",
Buckets = new List<PlannerPlanConfigurationBucketLocalization>
{
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "deliveryBucket",
Name = "Entregas",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "storePickupBucket",
Name = "Recogida",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "specialOrdersBucket",
Name = "Pedidos especiales",
},
new PlannerPlanConfigurationBucketLocalization
{
ExternalBucketId = "specialOrdersBucket",
Name = "Devoluciones de clientes",
},
},
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Solutions.BusinessScenarios["{businessScenario-id}"].Planner.PlanConfiguration.PatchAsync(requestBody);
mgc-beta solutions business-scenarios planner plan-configuration patch --business-scenario-id {businessScenario-id} --body '{\
"defaultLanguage": "en-us",\
"buckets": [\
{\
"externalBucketId": "deliveryBucket"\
},\
{\
"externalBucketId": "storePickupBucket"\
},\
{\
"externalBucketId": "specialOrdersBucket"\
},\
{\
"externalBucketId": "returnProcessingBucket"\
}\
],\
"localizations": [\
{\
"id": "en-us",\
"languageTag": "en-us",\
"planTitle": "Order Tracking",\
"buckets": [\
{\
"externalBucketId": "deliveryBucket",\
"name": "Deliveries"\
},\
{\
"externalBucketId": "storePickupBucket",\
"name": "Pickup"\
},\
{\
"externalBucketId": "specialOrdersBucket",\
"name": "Special Orders"\
},\
{\
"externalBucketId": "returnProcessingBucket",\
"name": "Customer Returns"\
}\
]\
},\
{\
"id": "es-es",\
"languageTag": "es-es",\
"planTitle": "Seguimiento de pedidos",\
"buckets": [\
{\
"externalBucketId": "deliveryBucket",\
"name": "Entregas"\
},\
{\
"externalBucketId": "storePickupBucket",\
"name": "Recogida"\
},\
{\
"externalBucketId": "specialOrdersBucket",\
"name": "Pedidos especiales"\
},\
{\
"externalBucketId": "specialOrdersBucket",\
"name": "Devoluciones de clientes"\
}\
]\
}\
]\
}\
'
// 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"
graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewPlannerPlanConfiguration()
defaultLanguage := "en-us"
requestBody.SetDefaultLanguage(&defaultLanguage)
plannerPlanConfigurationBucketDefinition := graphmodels.NewPlannerPlanConfigurationBucketDefinition()
externalBucketId := "deliveryBucket"
plannerPlanConfigurationBucketDefinition.SetExternalBucketId(&externalBucketId)
plannerPlanConfigurationBucketDefinition1 := graphmodels.NewPlannerPlanConfigurationBucketDefinition()
externalBucketId := "storePickupBucket"
plannerPlanConfigurationBucketDefinition1.SetExternalBucketId(&externalBucketId)
plannerPlanConfigurationBucketDefinition2 := graphmodels.NewPlannerPlanConfigurationBucketDefinition()
externalBucketId := "specialOrdersBucket"
plannerPlanConfigurationBucketDefinition2.SetExternalBucketId(&externalBucketId)
plannerPlanConfigurationBucketDefinition3 := graphmodels.NewPlannerPlanConfigurationBucketDefinition()
externalBucketId := "returnProcessingBucket"
plannerPlanConfigurationBucketDefinition3.SetExternalBucketId(&externalBucketId)
buckets := []graphmodels.PlannerPlanConfigurationBucketDefinitionable {
plannerPlanConfigurationBucketDefinition,
plannerPlanConfigurationBucketDefinition1,
plannerPlanConfigurationBucketDefinition2,
plannerPlanConfigurationBucketDefinition3,
}
requestBody.SetBuckets(buckets)
plannerPlanConfigurationLocalization := graphmodels.NewPlannerPlanConfigurationLocalization()
id := "en-us"
plannerPlanConfigurationLocalization.SetId(&id)
languageTag := "en-us"
plannerPlanConfigurationLocalization.SetLanguageTag(&languageTag)
planTitle := "Order Tracking"
plannerPlanConfigurationLocalization.SetPlanTitle(&planTitle)
plannerPlanConfigurationBucketLocalization := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "deliveryBucket"
plannerPlanConfigurationBucketLocalization.SetExternalBucketId(&externalBucketId)
name := "Deliveries"
plannerPlanConfigurationBucketLocalization.SetName(&name)
plannerPlanConfigurationBucketLocalization1 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "storePickupBucket"
plannerPlanConfigurationBucketLocalization1.SetExternalBucketId(&externalBucketId)
name := "Pickup"
plannerPlanConfigurationBucketLocalization1.SetName(&name)
plannerPlanConfigurationBucketLocalization2 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "specialOrdersBucket"
plannerPlanConfigurationBucketLocalization2.SetExternalBucketId(&externalBucketId)
name := "Special Orders"
plannerPlanConfigurationBucketLocalization2.SetName(&name)
plannerPlanConfigurationBucketLocalization3 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "returnProcessingBucket"
plannerPlanConfigurationBucketLocalization3.SetExternalBucketId(&externalBucketId)
name := "Customer Returns"
plannerPlanConfigurationBucketLocalization3.SetName(&name)
buckets := []graphmodels.PlannerPlanConfigurationBucketLocalizationable {
plannerPlanConfigurationBucketLocalization,
plannerPlanConfigurationBucketLocalization1,
plannerPlanConfigurationBucketLocalization2,
plannerPlanConfigurationBucketLocalization3,
}
plannerPlanConfigurationLocalization.SetBuckets(buckets)
plannerPlanConfigurationLocalization1 := graphmodels.NewPlannerPlanConfigurationLocalization()
id := "es-es"
plannerPlanConfigurationLocalization1.SetId(&id)
languageTag := "es-es"
plannerPlanConfigurationLocalization1.SetLanguageTag(&languageTag)
planTitle := "Seguimiento de pedidos"
plannerPlanConfigurationLocalization1.SetPlanTitle(&planTitle)
plannerPlanConfigurationBucketLocalization := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "deliveryBucket"
plannerPlanConfigurationBucketLocalization.SetExternalBucketId(&externalBucketId)
name := "Entregas"
plannerPlanConfigurationBucketLocalization.SetName(&name)
plannerPlanConfigurationBucketLocalization1 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "storePickupBucket"
plannerPlanConfigurationBucketLocalization1.SetExternalBucketId(&externalBucketId)
name := "Recogida"
plannerPlanConfigurationBucketLocalization1.SetName(&name)
plannerPlanConfigurationBucketLocalization2 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "specialOrdersBucket"
plannerPlanConfigurationBucketLocalization2.SetExternalBucketId(&externalBucketId)
name := "Pedidos especiales"
plannerPlanConfigurationBucketLocalization2.SetName(&name)
plannerPlanConfigurationBucketLocalization3 := graphmodels.NewPlannerPlanConfigurationBucketLocalization()
externalBucketId := "specialOrdersBucket"
plannerPlanConfigurationBucketLocalization3.SetExternalBucketId(&externalBucketId)
name := "Devoluciones de clientes"
plannerPlanConfigurationBucketLocalization3.SetName(&name)
buckets := []graphmodels.PlannerPlanConfigurationBucketLocalizationable {
plannerPlanConfigurationBucketLocalization,
plannerPlanConfigurationBucketLocalization1,
plannerPlanConfigurationBucketLocalization2,
plannerPlanConfigurationBucketLocalization3,
}
plannerPlanConfigurationLocalization1.SetBuckets(buckets)
localizations := []graphmodels.PlannerPlanConfigurationLocalizationable {
plannerPlanConfigurationLocalization,
plannerPlanConfigurationLocalization1,
}
requestBody.SetLocalizations(localizations)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
planConfiguration, err := graphClient.Solutions().BusinessScenarios().ByBusinessScenarioId("businessScenario-id").Planner().PlanConfiguration().Patch(context.Background(), requestBody, nil)
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
PlannerPlanConfiguration plannerPlanConfiguration = new PlannerPlanConfiguration();
plannerPlanConfiguration.setDefaultLanguage("en-us");
LinkedList<PlannerPlanConfigurationBucketDefinition> buckets = new LinkedList<PlannerPlanConfigurationBucketDefinition>();
PlannerPlanConfigurationBucketDefinition plannerPlanConfigurationBucketDefinition = new PlannerPlanConfigurationBucketDefinition();
plannerPlanConfigurationBucketDefinition.setExternalBucketId("deliveryBucket");
buckets.add(plannerPlanConfigurationBucketDefinition);
PlannerPlanConfigurationBucketDefinition plannerPlanConfigurationBucketDefinition1 = new PlannerPlanConfigurationBucketDefinition();
plannerPlanConfigurationBucketDefinition1.setExternalBucketId("storePickupBucket");
buckets.add(plannerPlanConfigurationBucketDefinition1);
PlannerPlanConfigurationBucketDefinition plannerPlanConfigurationBucketDefinition2 = new PlannerPlanConfigurationBucketDefinition();
plannerPlanConfigurationBucketDefinition2.setExternalBucketId("specialOrdersBucket");
buckets.add(plannerPlanConfigurationBucketDefinition2);
PlannerPlanConfigurationBucketDefinition plannerPlanConfigurationBucketDefinition3 = new PlannerPlanConfigurationBucketDefinition();
plannerPlanConfigurationBucketDefinition3.setExternalBucketId("returnProcessingBucket");
buckets.add(plannerPlanConfigurationBucketDefinition3);
plannerPlanConfiguration.setBuckets(buckets);
LinkedList<PlannerPlanConfigurationLocalization> localizations = new LinkedList<PlannerPlanConfigurationLocalization>();
PlannerPlanConfigurationLocalization plannerPlanConfigurationLocalization = new PlannerPlanConfigurationLocalization();
plannerPlanConfigurationLocalization.setId("en-us");
plannerPlanConfigurationLocalization.setLanguageTag("en-us");
plannerPlanConfigurationLocalization.setPlanTitle("Order Tracking");
LinkedList<PlannerPlanConfigurationBucketLocalization> buckets1 = new LinkedList<PlannerPlanConfigurationBucketLocalization>();
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization.setExternalBucketId("deliveryBucket");
plannerPlanConfigurationBucketLocalization.setName("Deliveries");
buckets1.add(plannerPlanConfigurationBucketLocalization);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization1 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization1.setExternalBucketId("storePickupBucket");
plannerPlanConfigurationBucketLocalization1.setName("Pickup");
buckets1.add(plannerPlanConfigurationBucketLocalization1);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization2 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization2.setExternalBucketId("specialOrdersBucket");
plannerPlanConfigurationBucketLocalization2.setName("Special Orders");
buckets1.add(plannerPlanConfigurationBucketLocalization2);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization3 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization3.setExternalBucketId("returnProcessingBucket");
plannerPlanConfigurationBucketLocalization3.setName("Customer Returns");
buckets1.add(plannerPlanConfigurationBucketLocalization3);
plannerPlanConfigurationLocalization.setBuckets(buckets1);
localizations.add(plannerPlanConfigurationLocalization);
PlannerPlanConfigurationLocalization plannerPlanConfigurationLocalization1 = new PlannerPlanConfigurationLocalization();
plannerPlanConfigurationLocalization1.setId("es-es");
plannerPlanConfigurationLocalization1.setLanguageTag("es-es");
plannerPlanConfigurationLocalization1.setPlanTitle("Seguimiento de pedidos");
LinkedList<PlannerPlanConfigurationBucketLocalization> buckets2 = new LinkedList<PlannerPlanConfigurationBucketLocalization>();
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization4 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization4.setExternalBucketId("deliveryBucket");
plannerPlanConfigurationBucketLocalization4.setName("Entregas");
buckets2.add(plannerPlanConfigurationBucketLocalization4);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization5 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization5.setExternalBucketId("storePickupBucket");
plannerPlanConfigurationBucketLocalization5.setName("Recogida");
buckets2.add(plannerPlanConfigurationBucketLocalization5);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization6 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization6.setExternalBucketId("specialOrdersBucket");
plannerPlanConfigurationBucketLocalization6.setName("Pedidos especiales");
buckets2.add(plannerPlanConfigurationBucketLocalization6);
PlannerPlanConfigurationBucketLocalization plannerPlanConfigurationBucketLocalization7 = new PlannerPlanConfigurationBucketLocalization();
plannerPlanConfigurationBucketLocalization7.setExternalBucketId("specialOrdersBucket");
plannerPlanConfigurationBucketLocalization7.setName("Devoluciones de clientes");
buckets2.add(plannerPlanConfigurationBucketLocalization7);
plannerPlanConfigurationLocalization1.setBuckets(buckets2);
localizations.add(plannerPlanConfigurationLocalization1);
plannerPlanConfiguration.setLocalizations(localizations);
PlannerPlanConfiguration result = graphClient.solutions().businessScenarios().byBusinessScenarioId("{businessScenario-id}").planner().planConfiguration().patch(plannerPlanConfiguration);
const options = {
authProvider,
};
const client = Client.init(options);
const plannerPlanConfiguration = {
defaultLanguage: 'en-us',
buckets: [
{
externalBucketId: 'deliveryBucket'
},
{
externalBucketId: 'storePickupBucket'
},
{
externalBucketId: 'specialOrdersBucket'
},
{
externalBucketId: 'returnProcessingBucket'
}
],
localizations: [
{
id: 'en-us',
languageTag: 'en-us',
planTitle: 'Order Tracking',
buckets: [
{
externalBucketId: 'deliveryBucket',
name: 'Deliveries'
},
{
externalBucketId: 'storePickupBucket',
name: 'Pickup'
},
{
externalBucketId: 'specialOrdersBucket',
name: 'Special Orders'
},
{
externalBucketId: 'returnProcessingBucket',
name: 'Customer Returns'
}
]
},
{
id: 'es-es',
languageTag: 'es-es',
planTitle: 'Seguimiento de pedidos',
buckets: [
{
externalBucketId: 'deliveryBucket',
name: 'Entregas'
},
{
externalBucketId: 'storePickupBucket',
name: 'Recogida'
},
{
externalBucketId: 'specialOrdersBucket',
name: 'Pedidos especiales'
},
{
externalBucketId: 'specialOrdersBucket',
name: 'Devoluciones de clientes'
}
]
}
]
};
await client.api('/solutions/businessScenarios/c5d514e6c6864911ac46c720affb6e4d/planner/planConfiguration')
.version('beta')
.update(plannerPlanConfiguration);
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\PlannerPlanConfiguration;
use Microsoft\Graph\Beta\Generated\Models\PlannerPlanConfigurationBucketDefinition;
use Microsoft\Graph\Beta\Generated\Models\PlannerPlanConfigurationLocalization;
use Microsoft\Graph\Beta\Generated\Models\PlannerPlanConfigurationBucketLocalization;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new PlannerPlanConfiguration();
$requestBody->setDefaultLanguage('en-us');
$bucketsPlannerPlanConfigurationBucketDefinition1 = new PlannerPlanConfigurationBucketDefinition();
$bucketsPlannerPlanConfigurationBucketDefinition1->setExternalBucketId('deliveryBucket');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketDefinition1;
$bucketsPlannerPlanConfigurationBucketDefinition2 = new PlannerPlanConfigurationBucketDefinition();
$bucketsPlannerPlanConfigurationBucketDefinition2->setExternalBucketId('storePickupBucket');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketDefinition2;
$bucketsPlannerPlanConfigurationBucketDefinition3 = new PlannerPlanConfigurationBucketDefinition();
$bucketsPlannerPlanConfigurationBucketDefinition3->setExternalBucketId('specialOrdersBucket');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketDefinition3;
$bucketsPlannerPlanConfigurationBucketDefinition4 = new PlannerPlanConfigurationBucketDefinition();
$bucketsPlannerPlanConfigurationBucketDefinition4->setExternalBucketId('returnProcessingBucket');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketDefinition4;
$requestBody->setBuckets($bucketsArray);
$localizationsPlannerPlanConfigurationLocalization1 = new PlannerPlanConfigurationLocalization();
$localizationsPlannerPlanConfigurationLocalization1->setId('en-us');
$localizationsPlannerPlanConfigurationLocalization1->setLanguageTag('en-us');
$localizationsPlannerPlanConfigurationLocalization1->setPlanTitle('Order Tracking');
$bucketsPlannerPlanConfigurationBucketLocalization1 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization1->setExternalBucketId('deliveryBucket');
$bucketsPlannerPlanConfigurationBucketLocalization1->setName('Deliveries');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization1;
$bucketsPlannerPlanConfigurationBucketLocalization2 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization2->setExternalBucketId('storePickupBucket');
$bucketsPlannerPlanConfigurationBucketLocalization2->setName('Pickup');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization2;
$bucketsPlannerPlanConfigurationBucketLocalization3 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization3->setExternalBucketId('specialOrdersBucket');
$bucketsPlannerPlanConfigurationBucketLocalization3->setName('Special Orders');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization3;
$bucketsPlannerPlanConfigurationBucketLocalization4 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization4->setExternalBucketId('returnProcessingBucket');
$bucketsPlannerPlanConfigurationBucketLocalization4->setName('Customer Returns');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization4;
$localizationsPlannerPlanConfigurationLocalization1->setBuckets($bucketsArray);
$localizationsArray []= $localizationsPlannerPlanConfigurationLocalization1;
$localizationsPlannerPlanConfigurationLocalization2 = new PlannerPlanConfigurationLocalization();
$localizationsPlannerPlanConfigurationLocalization2->setId('es-es');
$localizationsPlannerPlanConfigurationLocalization2->setLanguageTag('es-es');
$localizationsPlannerPlanConfigurationLocalization2->setPlanTitle('Seguimiento de pedidos');
$bucketsPlannerPlanConfigurationBucketLocalization1 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization1->setExternalBucketId('deliveryBucket');
$bucketsPlannerPlanConfigurationBucketLocalization1->setName('Entregas');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization1;
$bucketsPlannerPlanConfigurationBucketLocalization2 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization2->setExternalBucketId('storePickupBucket');
$bucketsPlannerPlanConfigurationBucketLocalization2->setName('Recogida');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization2;
$bucketsPlannerPlanConfigurationBucketLocalization3 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization3->setExternalBucketId('specialOrdersBucket');
$bucketsPlannerPlanConfigurationBucketLocalization3->setName('Pedidos especiales');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization3;
$bucketsPlannerPlanConfigurationBucketLocalization4 = new PlannerPlanConfigurationBucketLocalization();
$bucketsPlannerPlanConfigurationBucketLocalization4->setExternalBucketId('specialOrdersBucket');
$bucketsPlannerPlanConfigurationBucketLocalization4->setName('Devoluciones de clientes');
$bucketsArray []= $bucketsPlannerPlanConfigurationBucketLocalization4;
$localizationsPlannerPlanConfigurationLocalization2->setBuckets($bucketsArray);
$localizationsArray []= $localizationsPlannerPlanConfigurationLocalization2;
$requestBody->setLocalizations($localizationsArray);
$result = $graphServiceClient->solutions()->businessScenarios()->byBusinessScenarioId('businessScenario-id')->planner()->planConfiguration()->patch($requestBody)->wait();
Import-Module Microsoft.Graph.Beta.BusinessScenario
$params = @{
defaultLanguage = "en-us"
buckets = @(
@{
externalBucketId = "deliveryBucket"
}
@{
externalBucketId = "storePickupBucket"
}
@{
externalBucketId = "specialOrdersBucket"
}
@{
externalBucketId = "returnProcessingBucket"
}
)
localizations = @(
@{
id = "en-us"
languageTag = "en-us"
planTitle = "Order Tracking"
buckets = @(
@{
externalBucketId = "deliveryBucket"
name = "Deliveries"
}
@{
externalBucketId = "storePickupBucket"
name = "Pickup"
}
@{
externalBucketId = "specialOrdersBucket"
name = "Special Orders"
}
@{
externalBucketId = "returnProcessingBucket"
name = "Customer Returns"
}
)
}
@{
id = "es-es"
languageTag = "es-es"
planTitle = "Seguimiento de pedidos"
buckets = @(
@{
externalBucketId = "deliveryBucket"
name = "Entregas"
}
@{
externalBucketId = "storePickupBucket"
name = "Recogida"
}
@{
externalBucketId = "specialOrdersBucket"
name = "Pedidos especiales"
}
@{
externalBucketId = "specialOrdersBucket"
name = "Devoluciones de clientes"
}
)
}
)
}
Update-MgBetaSolutionBusinessScenarioPlannerPlanConfiguration -BusinessScenarioId $businessScenarioId -BodyParameter $params
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.planner_plan_configuration import PlannerPlanConfiguration
from msgraph_beta.generated.models.planner_plan_configuration_bucket_definition import PlannerPlanConfigurationBucketDefinition
from msgraph_beta.generated.models.planner_plan_configuration_localization import PlannerPlanConfigurationLocalization
from msgraph_beta.generated.models.planner_plan_configuration_bucket_localization import PlannerPlanConfigurationBucketLocalization
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = PlannerPlanConfiguration(
default_language = "en-us",
buckets = [
PlannerPlanConfigurationBucketDefinition(
external_bucket_id = "deliveryBucket",
),
PlannerPlanConfigurationBucketDefinition(
external_bucket_id = "storePickupBucket",
),
PlannerPlanConfigurationBucketDefinition(
external_bucket_id = "specialOrdersBucket",
),
PlannerPlanConfigurationBucketDefinition(
external_bucket_id = "returnProcessingBucket",
),
],
localizations = [
PlannerPlanConfigurationLocalization(
id = "en-us",
language_tag = "en-us",
plan_title = "Order Tracking",
buckets = [
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "deliveryBucket",
name = "Deliveries",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "storePickupBucket",
name = "Pickup",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "specialOrdersBucket",
name = "Special Orders",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "returnProcessingBucket",
name = "Customer Returns",
),
],
),
PlannerPlanConfigurationLocalization(
id = "es-es",
language_tag = "es-es",
plan_title = "Seguimiento de pedidos",
buckets = [
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "deliveryBucket",
name = "Entregas",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "storePickupBucket",
name = "Recogida",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "specialOrdersBucket",
name = "Pedidos especiales",
),
PlannerPlanConfigurationBucketLocalization(
external_bucket_id = "specialOrdersBucket",
name = "Devoluciones de clientes",
),
],
),
],
)
result = await graph_client.solutions.business_scenarios.by_business_scenario_id('businessScenario-id').planner.plan_configuration.patch(request_body)