create_procurement_portal_preference
async
¶
create_procurement_portal_preference(
procurement_portal_name: ProcurementPortalName,
buyer_domain: BuyerDomain,
buyer_identifier: BasicStringWithoutSpace,
supplier_domain: SupplierDomain,
supplier_identifier: BasicStringWithoutSpace,
einvoice_delivery_enabled: bool,
purchase_order_retrieval_enabled: bool,
contacts: Contacts,
*,
config_overrides: Optional[AsyncInvoicingClientConfig] = None,
selector: Optional[ProcurementPortalPreferenceSelector] = None,
procurement_portal_shared_secret: Optional[SensitiveBasicStringWithoutSpace] = None,
procurement_portal_instance_endpoint: Optional[BasicStringWithoutSpace] = None,
test_env_preference: Optional[TestEnvPreferenceInput] = None,
einvoice_delivery_preference: Optional[EinvoiceDeliveryPreference] = None,
marketplace_punch_out_enabled: Optional[bool] = None,
marketplace_punch_out_preference: Optional[MarketplacePunchOutPreference] = None,
resource_tags: Optional[ResourceTagList] = None,
client_token: Optional[BasicStringWithoutSpace] = None,
) -> CreateProcurementPortalPreferenceResponse
This feature API is subject to changing at any time. For more information, see the Amazon Web Services Service Terms (Betas and Previews).
Creates a procurement portal preference configuration for e-invoice delivery and purchase order retrieval. This preference defines how invoices are delivered to a procurement portal and how purchase orders are retrieved.
Parameters:
-
procurement_portal_name(ProcurementPortalName) –The name of the procurement portal.
-
buyer_domain(BuyerDomain) –The domain identifier for the buyer in the procurement portal.
-
buyer_identifier(BasicStringWithoutSpace) –The unique identifier for the buyer in the procurement portal.
-
supplier_domain(SupplierDomain) –The domain identifier for the supplier in the procurement portal.
-
supplier_identifier(BasicStringWithoutSpace) –The unique identifier for the supplier in the procurement portal.
-
procurement_portal_shared_secret(Optional[SensitiveBasicStringWithoutSpace], default:None) –The shared secret or authentication credential used to establish secure communication with the procurement portal. This value must be encrypted at rest.
-
procurement_portal_instance_endpoint(Optional[BasicStringWithoutSpace], default:None) –The endpoint URL where e-invoices will be delivered to the procurement portal. Must be a valid HTTPS URL.
-
test_env_preference(Optional[TestEnvPreferenceInput], default:None) –Configuration settings for the test environment of the procurement portal. Includes test credentials and endpoints that are used for validation before production deployment.
-
einvoice_delivery_enabled(bool) –Indicates whether e-invoice delivery is enabled for this procurement portal preference. Set to true to enable e-invoice delivery, false to disable.
-
einvoice_delivery_preference(Optional[EinvoiceDeliveryPreference], default:None) –Specifies the e-invoice delivery configuration including document types, attachment types, and customization settings for the portal.
-
purchase_order_retrieval_enabled(bool) –Indicates whether purchase order retrieval is enabled for this procurement portal preference. Set to true to enable PO retrieval, false to disable.
-
marketplace_punch_out_enabled(Optional[bool], default:None) –Defaults to false if not provided.
-
marketplace_punch_out_preference(Optional[MarketplacePunchOutPreference], default:None) –Required for Coupa when MarketplacePunchOutEnabled is true.
-
contacts(Contacts) –List of contact information for portal administrators and technical contacts responsible for the e-invoice integration.
-
resource_tags(Optional[ResourceTagList], default:None) –The tags to apply to this procurement portal preference resource. Each tag consists of a key and an optional value.
-
client_token(Optional[BasicStringWithoutSpace], default:None) –A unique, case-sensitive identifier that you provide to ensure idempotency of the request.
Raises:
-
AccessDeniedException–You don't have sufficient access to perform this action.
-
ConflictException–The request could not be completed due to a conflict with the current state of the resource. This exception occurs when a concurrent modification is detected during an update operation, or when attempting to create a resource that already exists.
-
InternalServerException–The processing request failed because of an unknown error, exception, or failure.
-
ServiceQuotaExceededException–The request was rejected because it attempted to create resources beyond the current Amazon Web Services account limits. The error message describes the limit exceeded.
-
ThrottlingException–The request was denied due to request throttling.
-
ValidationException–The input fails to satisfy the constraints specified by an Amazon Web Services service.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
CreateProcurementPortalPreference for Coupa
>>> await client.create_procurement_portal_preference(procurement_portal_name='COUPA', buyer_domain='NetworkID', buyer_identifier='BuyerId_1', supplier_domain='NetworkID', supplier_identifier='SupplierId_1', selector={'InvoiceUnitArns': ['arn:aws:invoicing::111111111111:invoice-unit/12345678', 'arn:aws:invoicing::111111111111:invoice-unit/12345679'], 'SellerOfRecords': ['AWS_INC', 'AWS_EUROPE']}, procurement_portal_shared_secret='Coupa_Secret', procurement_portal_instance_endpoint='https://www.placeholder-domain.test', test_env_preference={'BuyerDomain': 'NetworkID', 'BuyerIdentifier': 'BuyerId_1_Test', 'SupplierDomain': 'NetworkID', 'SupplierIdentifier': 'SupplierId_1_Test', 'ProcurementPortalSharedSecret': 'Coupa_Secret_test', 'ProcurementPortalInstanceEndpoint': 'https://www.placeholder-domain.test'}, einvoice_delivery_enabled=True, einvoice_delivery_preference={'EinvoiceDeliveryDocumentTypes': ['AWS_CLOUD_INVOICE'], 'EinvoiceDeliveryAttachmentTypes': ['INVOICE_PDF'], 'Protocol': 'CXML', 'PurchaseOrderDataSources': [{'EinvoiceDeliveryDocumentType': 'AWS_CLOUD_INVOICE', 'PurchaseOrderDataSourceType': 'ASSOCIATED_PURCHASE_ORDER_REQUIRED'}], 'ConnectionTestingMethod': 'PROD_ENV_DOLLAR_TEST', 'EinvoiceDeliveryActivationDate': 1750279280.091}, purchase_order_retrieval_enabled=True, marketplace_punch_out_enabled=True, marketplace_punch_out_preference={'ApprovalRequestRedirectUrl': 'https://www.placeholder-domain.test/approvals'}, contacts=[{'Name': 'John Doe', 'Email': '[email protected]'}], resource_tags=[{'Key': 'testKey', 'Value': 'testValue'}], client_token='e362c68e-4e74-48d7-9228-0bc5aa447b42')
Source code in docs_src/capo_invoicing/_services/async_invoicing.py
369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 | |