Class: NewStoreApi::PhavdaNotificationsController
- Inherits:
-
BaseController
- Object
- BaseController
- NewStoreApi::PhavdaNotificationsController
- Defined in:
- lib/new_store_api/controllers/phavda_notifications_controller.rb
Overview
PhavdaNotificationsController
Constant Summary
Constants inherited from BaseController
Instance Attribute Summary
Attributes inherited from BaseController
Instance Method Summary collapse
-
#create_phavda_notification(event_name, x_request_id, x_tenant, x_newstore_tenant, idempotency_key, body, team: nil) ⇒ void
🚧 BETA: This endpoint is in beta and may change.
Methods inherited from BaseController
#initialize, #new_parameter, #new_request_builder, #new_response_handler, user_agent
Constructor Details
This class inherits a constructor from NewStoreApi::BaseController
Instance Method Details
#create_phavda_notification(event_name, x_request_id, x_tenant, x_newstore_tenant, idempotency_key, body, team: nil) ⇒ void
This method returns an undefined value.
🚧 BETA: This endpoint is in beta and may change.here here description here for every message, else the existing message will be overwritten. Only alpha-numeric values and hyphens with size between 4 and 64 is allowed. Eg: fcbe151f-7ff4-4fd3-ab14-c5f564932f8b
See API Lifecycle Documentation for details.32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56
# File 'lib/new_store_api/controllers/phavda_notifications_controller.rb', line 32 def create_phavda_notification(event_name, x_request_id, x_tenant, x_newstore_tenant, idempotency_key, body, team: nil) @api_call .request(new_request_builder(HttpMethodEnum::POST, '/order-management/notifications', Server::API) .header_param(new_parameter(event_name, key: 'event-name')) .header_param(new_parameter(x_request_id, key: 'x-request-id')) .header_param(new_parameter(x_tenant, key: 'x-tenant')) .header_param(new_parameter(x_newstore_tenant, key: 'x-newstore-tenant')) .header_param(new_parameter(idempotency_key, key: 'idempotency-key')) .header_param(new_parameter('application/json', key: 'Content-Type')) .body_param(new_parameter(body)) .header_param(new_parameter(team, key: 'team')) .body_serializer(APIHelper.method(:json_serialize)) .auth(Single.new('oauth'))) .response(new_response_handler .is_response_void(true)) .execute end