1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #include <aws/budgets/model/CreateSubscriberRequest.h> 7 #include <aws/core/utils/json/JsonSerializer.h> 8 9 #include <utility> 10 11 using namespace Aws::Budgets::Model; 12 using namespace Aws::Utils::Json; 13 using namespace Aws::Utils; 14 CreateSubscriberRequest()15CreateSubscriberRequest::CreateSubscriberRequest() : 16 m_accountIdHasBeenSet(false), 17 m_budgetNameHasBeenSet(false), 18 m_notificationHasBeenSet(false), 19 m_subscriberHasBeenSet(false) 20 { 21 } 22 SerializePayload() const23Aws::String CreateSubscriberRequest::SerializePayload() const 24 { 25 JsonValue payload; 26 27 if(m_accountIdHasBeenSet) 28 { 29 payload.WithString("AccountId", m_accountId); 30 31 } 32 33 if(m_budgetNameHasBeenSet) 34 { 35 payload.WithString("BudgetName", m_budgetName); 36 37 } 38 39 if(m_notificationHasBeenSet) 40 { 41 payload.WithObject("Notification", m_notification.Jsonize()); 42 43 } 44 45 if(m_subscriberHasBeenSet) 46 { 47 payload.WithObject("Subscriber", m_subscriber.Jsonize()); 48 49 } 50 51 return payload.View().WriteReadable(); 52 } 53 GetRequestSpecificHeaders() const54Aws::Http::HeaderValueCollection CreateSubscriberRequest::GetRequestSpecificHeaders() const 55 { 56 Aws::Http::HeaderValueCollection headers; 57 headers.insert(Aws::Http::HeaderValuePair("X-Amz-Target", "AWSBudgetServiceGateway.CreateSubscriber")); 58 return headers; 59 60 } 61 62 63 64 65