### Signature Calculation Examples Source: https://api-docs.mykeeta.com/apis/opendelivery/.md Provides examples of signature string generation for different request types (GET, POST, PUT) including scenarios with query parameters and JSON bodies. ```curl Example 1: GET Request with Query Parameters Request: URL: https://api.example.com/v1/users Query Parameters: {page: "2", limit: "10", sort: "name"} Body: (empty) Signature String: https://api.example.com/v1/users&limit=10&page=2&sort=name Example 2: POST Request with JSON Body Request: URL: https://api.example.com/v1/orders Query Parameters: (empty) Body: {"userId": 123, "productId": 456, "quantity": 2} Signature String: https://api.example.com/v1/orders&{"userId":123,"productId":456,"quantity":2} Example 3: PUT Request with Both Query Parameters and Body Request: URL: https://api.example.com/v1/products Query Parameters: {version: "v2", format: "json"} Body: {"name": "Product A", "price": 99.99} Signature String: https://api.example.com/v1/products&format=json&version=v2&{"name":"Product A","price":99.99} ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderswebhook/webhook-headers Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### cURL Example for Get New Events Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/query-new-order-events Example cURL command to poll for new events, specifying event types and merchant identifiers. Includes necessary headers for authentication and authorization. ```curl curl -i -X GET \ 'https://open.mykeeta.com/api/open/opendelivery/v1/events:polling?eventType=CREATED' \ -H 'Authorization: Bearer ' \ -H 'X-App-Signature: YOUR_API_KEY_HERE' \ -H 'x-polling-merchants: 22815773000169-dbc7e35a-c936-4665-9e13-eb55eb8b6824' ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/how-to-start Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### cURL Example for Get New Events Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/pollingevents Example cURL command to poll for new events, specifying event types and merchant identifiers. Includes necessary headers for authentication and authorization. ```curl curl -i -X GET \ 'https://open.mykeeta.com/api/open/opendelivery/v1/events:polling?eventType=CREATED' \ -H 'Authorization: Bearer ' \ -H 'X-App-Signature: YOUR_API_KEY_HERE' \ -H 'x-polling-merchants: 22815773000169-dbc7e35a-c936-4665-9e13-eb55eb8b6824' ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### cURL Example for Get New Events Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/pollingacknowledgment Example cURL command to poll for new events, specifying event types and merchant identifiers. Includes necessary headers for authentication and authorization. ```curl curl -i -X GET \ 'https://open.mykeeta.com/api/open/opendelivery/v1/events:polling?eventType=CREATED' \ -H 'Authorization: Bearer ' \ -H 'X-App-Signature: YOUR_API_KEY_HERE' \ -H 'x-polling-merchants: 22815773000169-dbc7e35a-c936-4665-9e13-eb55eb8b6824' ``` -------------------------------- ### cURL Example for Get New Events Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/acknowledgment-events Example cURL command to poll for new events, specifying event types and merchant identifiers. Includes necessary headers for authentication and authorization. ```curl curl -i -X GET \ 'https://open.mykeeta.com/api/open/opendelivery/v1/events:polling?eventType=CREATED' \ -H 'Authorization: Bearer ' \ -H 'X-App-Signature: YOUR_API_KEY_HERE' \ -H 'x-polling-merchants: 22815773000169-dbc7e35a-c936-4665-9e13-eb55eb8b6824' ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/authentication/authentication/authentication/authentication/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Signature Calculation for GET Request Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/examples Example of calculating the HMAC-SHA256 signature for a GET request with query parameters in the Keeta Open Delivery API. This process involves extracting request components, building a signature string, and calculating the signature. ```APIDOC Example 1: GET Request with Query Parameters # Keeta Open Delivery API (v.1.0.1) ## Signature Calculation Steps: 1. **Extract Request Components:** Identify all components that need to be included in the signature string. 2. **Build Signature String:** Concatenate the extracted components in a specific order. 3. **Query Parameters Processing:** Ensure query parameters are processed correctly for signature generation. 4. **Calculate HMAC-SHA256 Signature:** Compute the signature using the HMAC-SHA256 algorithm. **Note:** The secret value in any provided scripts needs to be replaced with the one assigned by Keeta. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/authentication/authentication/authentication/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Signature Calculation for GET Request Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/example-1%3A-get-request-with-query-parameters Example of calculating the HMAC-SHA256 signature for a GET request with query parameters in the Keeta Open Delivery API. This process involves extracting request components, building a signature string, and calculating the signature. ```APIDOC Example 1: GET Request with Query Parameters # Keeta Open Delivery API (v.1.0.1) ## Signature Calculation Steps: 1. **Extract Request Components:** Identify all components that need to be included in the signature string. 2. **Build Signature String:** Concatenate the extracted components in a specific order. 3. **Query Parameters Processing:** Ensure query parameters are processed correctly for signature generation. 4. **Calculate HMAC-SHA256 Signature:** Compute the signature using the HMAC-SHA256 algorithm. **Note:** The secret value in any provided scripts needs to be replaced with the one assigned by Keeta. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderapi/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Signature Calculation Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/2 Details the process of calculating HMAC-SHA256 signatures for API requests, including query parameter processing and examples for different HTTP methods (GET, POST, PUT). ```APIDOC ## Introduction to Signature Calculation Keeta requires Software Services to include a signature in the header of every API request to enhance security and prevent data leakage. ### Step 1: Extract Request Components Identify all components of the request that need to be included in the signature string. ### Step 2: Build Signature String Construct a string by concatenating the extracted request components in a specific order. #### 2.2 Query Parameters Processing Query parameters must be sorted alphabetically by key before being appended to the signature string. ### Step 3: Calculate HMAC-SHA256 Signature Calculate the HMAC-SHA256 hash of the signature string using your secret key. ### Examples #### Example 1: GET Request with Query Parameters ``` GET /orders?orderId=123×tamp=1678886400 SignatureString: orderId=123×tamp=1678886400 Signature: ``` #### Example 2: POST Request with JSON Body ``` POST /merchants { "merchantName": "Example Merchant", "address": "123 Main St" } SignatureString: {"merchantName":"Example Merchant","address":"123 Main St"}×tamp=1678886400 Signature: ``` #### Example 3: PUT Request with Both Query Parameters and Body ``` PUT /orders/123?status=completed×tamp=1678886400 { "trackingNumber": "XYZ789" } SignatureString: status=completed×tamp=1678886400{"trackingNumber":"XYZ789"} Signature: ``` ### Signature calculation script example (Refer to Postman Collection for script details) **Important:** You need to replace the secret value in the Postman script with the one assigned to you by Keeta. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderapi/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Signature Calculation Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation Details the process of calculating HMAC-SHA256 signatures for API requests, including signature calculation script examples for GET, POST, and PUT requests with query parameters and JSON bodies. ```APIDOC Signature Calculation: Keeta requires Software Services to include a signature in the header of every API request to enhance security. Steps: 1. Extract Request Components 2. Build Signature String - Query Parameters Processing 3. Calculate HMAC-SHA256 Signature Examples: - Example 1: GET Request with Query Parameters - Example 2: POST Request with JSON Body - Example 3: PUT Request with Both Query Parameters and Body Signature calculation script example provided for implementation reference. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Signature Calculation Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/code-implementation-referencethe Details the process of calculating HMAC-SHA256 signatures for API requests, including signature calculation script examples for GET, POST, and PUT requests with query parameters and JSON bodies. ```APIDOC Signature Calculation: Keeta requires Software Services to include a signature in the header of every API request to enhance security. Steps: 1. Extract Request Components 2. Build Signature String - Query Parameters Processing 3. Calculate HMAC-SHA256 Signature Examples: - Example 1: GET Request with Query Parameters - Example 2: POST Request with JSON Body - Example 3: PUT Request with Both Query Parameters and Body Signature calculation script example provided for implementation reference. ``` -------------------------------- ### Keeta API Signature Calculation Source: https://api-docs.mykeeta.com/apis/opendelivery/section/Introduction-to-Signature-Calculation Details the process of calculating HMAC-SHA256 signatures for API requests, including signature calculation script examples for GET, POST, and PUT requests with query parameters and JSON bodies. ```APIDOC Signature Calculation: Keeta requires Software Services to include a signature in the header of every API request to enhance security. Steps: 1. Extract Request Components 2. Build Signature String - Query Parameters Processing 3. Calculate HMAC-SHA256 Signature Examples: - Example 1: GET Request with Query Parameters - Example 2: POST Request with JSON Body - Example 3: PUT Request with Both Query Parameters and Body Signature calculation script example provided for implementation reference. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderapi/authentication/authentication/authentication/authentication/authentication/introduction-to-developer-portal Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Signature String Examples Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/authentication/authentication/authentication/authentication/authentication/introduction-to-developer-portal Illustrates how the signature string is constructed for different types of requests, including GET requests with query parameters, POST requests with JSON bodies, and PUT requests with both query parameters and bodies. ```APIDOC Example 1: GET Request with Query Parameters Request: URL: https://api.example.com/v1/users Query Parameters: {page: "2", limit: "10", sort: "name"} Body: (empty) Signature String: https://api.example.com/v1/users&limit=10&page=2&sort=name Example 2: POST Request with JSON Body Request: URL: https://api.example.com/v1/orders Query Parameters: (empty) Body: {"userId": 123, "productId": 456, "quantity": 2} Signature String: https://api.example.com/v1/orders&{"userId":123,"productId":456,"quantity":2} Example 3: PUT Request with Both Query Parameters and Body Request: URL: https://api.example.com/v1/products Query Parameters: {version: "v2", format: "json"} Body: {"name": "Product A", "price": 99.99} Signature String: https://api.example.com/v1/products&format=json&version=v2&{"name":"Product A","price":99.99} ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/authentication/authentication/authentication/authentication/introduction-to-developer-portal Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Signature String Examples Source: https://api-docs.mykeeta.com/apis/opendelivery/orderapi/authentication/authentication/getauthorizationurl Illustrates how the signature string is constructed for different types of requests, including GET requests with query parameters, POST requests with JSON bodies, and PUT requests with both query parameters and bodies. ```APIDOC Example 1: GET Request with Query Parameters Request: URL: https://api.example.com/v1/users Query Parameters: {page: "2", limit: "10", sort: "name"} Body: (empty) Signature String: https://api.example.com/v1/users&limit=10&page=2&sort=name Example 2: POST Request with JSON Body Request: URL: https://api.example.com/v1/orders Query Parameters: (empty) Body: {"userId": 123, "productId": 456, "quantity": 2} Signature String: https://api.example.com/v1/orders&{"userId":123,"productId":456,"quantity":2} Example 3: PUT Request with Both Query Parameters and Body Request: URL: https://api.example.com/v1/products Query Parameters: {version: "v2", format: "json"} Body: {"name": "Product A", "price": 99.99} Signature String: https://api.example.com/v1/products&format=json&version=v2&{"name":"Product A","price":99.99} ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Signature Calculation for Keeta API Requests Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/example-3%3A-put-request-with-both-query-parameters-and-body Details the process of calculating HMAC-SHA256 signatures for API requests, including query parameter processing and examples for GET, POST, and PUT requests. This is crucial for security and preventing data leakage. ```APIDOC Signature Calculation: Step 1: Extract Request Components - Identify all components that need to be included in the signature string (e.g., HTTP method, path, query parameters, request body). Step 2: Build Signature String - Concatenate the extracted components in a specific order. - Query Parameters Processing: Sort query parameters alphabetically by key. Step 3: Calculate HMAC-SHA256 Signature - Use the generated signature string and your secret key to compute the HMAC-SHA256 hash. - The resulting hash is the signature. Examples: Example 1: GET Request with Query Parameters - Components: HTTP Method, Path, Sorted Query Parameters. Example 2: POST Request with JSON Body - Components: HTTP Method, Path, Request Body (often JSON stringified). Example 3: PUT Request with Both Query Parameters and Body - Components: HTTP Method, Path, Sorted Query Parameters, Request Body. Signature calculation script example is available for implementation reference. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderswebhook/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/authentication/authentication/authentication/introduction-to-developer-portal Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Signature Calculation Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/step-1%3A-extract-request-components Details the process of calculating HMAC-SHA256 signatures for API requests to Keeta's Open Delivery API. Includes steps for extracting request components, building the signature string, and handling query parameters. Provides examples for GET, POST, and PUT requests. ```APIDOC ## Introduction to Signature Calculation Keeta requires a signature in the header of every API request to enhance security and prevent data leakage. ### Step 1: Extract Request Components Identify all components of the request that need to be included in the signature string. ### Step 2: Build Signature String Concatenate the extracted request components in a specific order to form the signature string. #### 2.2 Query Parameters Processing Query parameters must be sorted alphabetically by key before being appended to the signature string. ### Step 3: Calculate HMAC-SHA256 Signature Calculate the HMAC-SHA256 hash of the signature string using your secret key. ### Examples #### Example 1: GET Request with Query Parameters ``` GET /orders?order_id=123&status=pending HTTP/1.1 Host: api.keeta.com ... ``` Signature String: `GET/orders?order_id=123&status=pending` #### Example 2: POST Request with JSON Body ``` POST /merchants HTTP/1.1 Host: api.keeta.com Content-Type: application/json ... {"merchant_name": "Example Merchant", "address": "123 Main St"} ``` Signature String: `POST/merchants{"merchant_name": "Example Merchant", "address": "123 Main St"}` #### Example 3: PUT Request with Both Query Parameters and Body ``` PUT /merchants/123?region=us-east HTTP/1.1 Host: api.keeta.com Content-Type: application/json ... {"status": "active"} ``` Signature String: `PUT/merchants/123?region=us-east{"status": "active"}` ### Signature calculation script example (Refer to Postman Collection for script details) ### Code Implementation Reference (Refer to Postman Collection for script details) ``` -------------------------------- ### Signature Calculation for Keeta API Requests Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/signature-calculation-script-example Details the process of calculating HMAC-SHA256 signatures for API requests to ensure security. This involves extracting request components, building a signature string with specific processing for query parameters, and calculating the final signature. Examples for GET, POST, and PUT requests are provided, along with a script implementation reference. ```APIDOC Signature Calculation Process: 1. **Extract Request Components:** Identify all relevant components of the API request, including HTTP method, endpoint path, query parameters, and request body (if applicable). 2. **Build Signature String:** Construct a canonical string by concatenating the extracted components in a predefined order. This typically involves sorting query parameters alphabetically. * **Query Parameters Processing:** Ensure query parameters are processed correctly, including handling of multiple values for the same key and URL encoding. 3. **Calculate HMAC-SHA256 Signature:** Compute the HMAC-SHA256 hash of the signature string using your secret key. 4. **Include Signature in Header:** Add the calculated signature to the `X-Signature` header of your API request. **Examples:** * **Example 1: GET Request with Query Parameters** * Method: GET * Path: /merchants * Query Parameters: `page=1&size=10` * Signature String: `GET/merchants?page=1&size=10` * Header: `X-Signature: ` * **Example 2: POST Request with JSON Body** * Method: POST * Path: /orders * Body: `{"orderId": "123", "items": [{"sku": "ABC"}]}` * Signature String: `POST/orders{"orderId": "123", "items": [{"sku": "ABC"}]}` * Header: `X-Signature: ` * **Example 3: PUT Request with Both Query Parameters and Body** * Method: PUT * Path: /merchants/1 * Query Parameters: `update_type=full` * Body: `{"name": "New Name"}` * Signature String: `PUT/merchants/1?update_type=full{"name": "New Name"}` * Header: `X-Signature: ` **Signature Calculation Script Example:** (Refer to external script for implementation details. Ensure to replace placeholder secret values with your assigned Keeta secret.) ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/authentication/authentication/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/introduction-to-signature-calculation/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Authentication: Get Access Token Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/introduction-to-keeta-test-app All Keeta API endpoints (except the Get Access Token endpoint itself) require authentication. Obtain an access token by calling the Get Access Token endpoint before making any further requests. ```APIDOC Get Access Token: - Obtain an access token for authenticating with Keeta API endpoints. - This is the first step in integrating with the Keeta API. - All subsequent API calls require this token in the header. ``` -------------------------------- ### Keeta API Authentication: Get Access Token Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/authentication/authentication/authentication/authentication/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app All Keeta API endpoints (except the Get Access Token endpoint itself) require authentication. Obtain an access token by calling the Get Access Token endpoint before making any further requests. ```APIDOC Get Access Token: - Obtain an access token for authenticating with Keeta API endpoints. - This is the first step in integrating with the Keeta API. - All subsequent API calls require this token in the header. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/authentication/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App. ```APIDOC Module: Promotion Settings & Test Orders Promotion Settings: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Methods for Placing Orders for Test Stores: 1. Developer Portal with Test Order Tool: - Log into Dev Portal. - Use Test Order Tool to place orders directly at the test store. - Convenient for rapid validation, but limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders directly within the app. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations for testing reverse order flows. Keeta Test App Setup: - Download link provided by Keeta team (Android and iOS). - Install the app. - Select the Bongolava region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### cURL Example for POST /v1/newEvent Source: https://api-docs.mykeeta.com/apis/opendelivery/orderswebhook/webhook-headers Example of how to call the /v1/newEvent endpoint using cURL, demonstrating the required headers and JSON payload structure. ```curl curl -i -X POST \ https://open.mykeeta.com/api/open/opendelivery/v1/newEvent \ -H 'Content-Type: application/json' \ -H 'X-App-Id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \ -H 'X-App-MerchantId: 22815773000169-dbc7e35a-c936-4665-9e13-eb55eb8b6824' \ -H 'X-App-Signature: string' \ -d '{ "eventId": "d6703cc8-9e79-415d-ac03-a4dc7f6ab43c", "eventType": "CREATED", "orderId": "b3e1eced-f2bd-4d8c-9765-fbc9d1d222d5", "orderURL": "http://example.com", "createdAt": "2019-08-24T14:15:22Z", "sourceAppId": "fb08c6b7-a844-43c6-b104-98e70c00fc20", "virtualBrand": "string", "metadata": "string" }' ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderapi/authentication/authentication/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/section/authentication/authentication/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Authentication: Get Access Token Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/authentication/authentication/authentication/authentication/introduction-to-keeta-test-app All Keeta API endpoints (except Get Access Token) require authentication. Obtain an access token by calling the Get Access Token endpoint before making any further requests. This token is essential for subsequent API calls. ```APIDOC Get Access Token: - Description: Obtains an access token for authenticating with the Keeta API. - Requirements: NDA signed, developer account created. - Usage: Call this endpoint before any other API requests. - Note: This is the only endpoint that does not require prior authentication. ``` -------------------------------- ### Promotion Settings and Test Order Methods Source: https://api-docs.mykeeta.com/apis/opendelivery/orderspolling/authentication/authentication/authentication/authentication/Introduction-to-Keeta-test-APP Configure marketing activities and test order processing. Place test orders using the Developer Portal's Test Order Tool or the Keeta Test App for a comprehensive user-perspective simulation. ```APIDOC Feature: Promotion Settings Recommendation: - Set up various marketing activities. - Place test orders in test stores to verify promotion information processing. Feature: Placing Orders for Test Stores Methods: 1. Developer Portal with Test Order Tool: - Login to Dev Portal, use Test Order Tool. - Convenient for rapid order flow validation. - Limited functionality. 2. Keeta Test App: - Download and use the Keeta Test App. - Browse store menus and place orders. - Enables full end-to-end simulation from user perspective. - Provides visualized menu interface. - Allows triggering refund operations (for testing reverse order flows). Keeta Test App Setup: - Download link provided by Keeta team (Android/iOS). - Install app. - Select 'Bongolava' region. - Complete user registration (Brazilian phone numbers supported). ``` -------------------------------- ### Keeta API Authentication: Get Access Token Source: https://api-docs.mykeeta.com/apis/opendelivery/merchantendpoints/authentication/authentication/authentication/Introduction-to-Signature-Calculation All Keeta API endpoints (except Get Access Token) require authentication. Obtain an access token by calling the Get Access Token endpoint before making any further requests. This token is essential for subsequent API calls. ```APIDOC Get Access Token: - Description: Obtains an access token for authenticating with the Keeta API. - Requirements: NDA signed, developer account created. - Usage: Call this endpoint before any other API requests. - Note: This is the only endpoint that does not require prior authentication. ``` -------------------------------- ### cURL Example for Merchant Authorization URL Source: https://api-docs.mykeeta.com/apis/opendelivery/authentication Example of how to request the merchant authorization URL using cURL. ```curl curl -i -X GET \ 'https://open.mykeeta.com/api/open/opendelivery/oauth/authorization/url?clientId=string' ```