{"id":12326,"date":"2025-08-15T00:39:04","date_gmt":"2025-08-14T22:39:04","guid":{"rendered":"https:\/\/help.mapal-os.com\/?p=12326"},"modified":"2026-01-27T15:43:33","modified_gmt":"2026-01-27T14:43:33","slug":"racuparer-les-donnaes-de-shifts-de-caisse-via-api","status":"publish","type":"post","link":"https:\/\/help.mapal-os.com\/fr\/analytics-fr\/cashrec-4\/racuparer-les-donnaes-de-shifts-de-caisse-via-api\/","title":{"rendered":"R\u00e9cup\u00e9rer les donn\u00e9es de shifts de caisse via API"},"content":{"rendered":"\n\n<p><strong>Start from:<\/strong> Your server-to-server integration (API client).<\/p>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\">The <strong>Cashrec API<\/strong><\/h2>\n\n\n\n\n\n\n<p>The <strong>Cashrec API<\/strong> is a RESTful service for fetching <strong>cash sheet data<\/strong> for specific business centers and date ranges.<\/p>\n\n\n\n\n\n\n<p><strong>Key Benefits:<\/strong><\/p>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li>Get detailed shift-level cash and sales info.<\/li>\n\n\n\n\n\n\n<li>Secure, encrypted server-to-server integration (HTTPS + JWT).<\/li>\n\n\n\n\n\n\n<li>Supports high-volume, real-time requests.<\/li>\n<\/ul>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\">Generate a JWT token<\/h2>\n\n\n\n\n\n\n<p><strong>POST to: <\/strong><a class=\"\" href=\"https:\/\/login.mapal-os.com\/connect\/token\">https:\/\/login.mapal-os.com\/connect\/token<\/a><\/p>\n\n\n\n\n\n\n<p><strong>Parameters:<\/strong><\/p>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li>grant_type=password<\/li>\n\n\n\n\n\n\n<li>username=<your_username><\/your_username><\/li>\n\n\n\n\n\n\n<li>password=<your_password><\/your_password><\/li>\n\n\n\n\n\n\n<li>client_id=wf_wap_tp<\/li>\n\n\n\n\n\n\n<li>client_secret=<shared_client_secret> (contact Customer Support to obtain)<br>Successful response fields: access_token, expires_in, token_type, refresh_token, scope.<\/shared_client_secret><\/li>\n<\/ul>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\">Include the token in requests<\/h2>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li><strong>Add the header:<\/strong> Authorization: Bearer {access_token}<\/li>\n<\/ul>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\">Get cash sheet information<\/h2>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li><strong>Base domain (OpenAPI):<\/strong> <a class=\"\" href=\"https:\/\/cashrec.api.pro.mapal-os.com\">https:\/\/cashrec.api.pro.mapal-os.com<\/a><\/li>\n\n\n\n\n\n\n<li><strong>Endpoint path: <\/strong>\/api\/v1\/cashSheet<\/li>\n\n\n\n\n\n\n<li><strong>Method:<\/strong> GET<\/li>\n\n\n\n\n\n\n<li><strong>Description: <\/strong>Retrieves detailed cash sheet information for a specified period and list of business centres.<\/li>\n<\/ul>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\">Query parameters<\/h2>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li><strong>startDate<\/strong> (format: yyyy-MM-ddTHH:mm:ss)<\/li>\n\n\n\n\n\n\n<li><strong>endDate <\/strong>(format: yyyy-MM-ddTHH:mm:ss)<\/li>\n\n\n\n\n\n\n<li><strong>centersList <\/strong>(comma?separated list of centre IDs)<\/li>\n\n\n\n\n\n\n<li><strong>Response: <\/strong>200 OK with cash sheet records for the requested period and centres.<\/li>\n<\/ul>\n\n\n\n\n\n\n<p><strong>Notes:<\/strong> Parameter naming may be case?sensitive. Use the exact names shown in your OpenAPI specification if they differ (for example, StartDate vs startDate). For the full request\/response schema and interactive documentation, see the OpenAPI specification at: <a class=\"\" href=\"https:\/\/cashrec.api.pro.mapal-os.com\/swagger\/index.html\">https:\/\/cashrec.api.pro.mapal-os.com\/swagger\/index.html<\/a><\/p>\n\n\n\n\n\n\n<h2 class=\"wp-block-heading\"><strong>API errors<\/strong><\/h2>\n\n\n\n\n\n\n<ul class=\"wp-block-list\">\n\n<li><strong>400 Bad Request: <\/strong>missing or invalid parameters. Example message code 100: \u201cInvalid parameters. You must provide valid StartDate, EndDate and CenterLists.\u201d<\/li>\n\n\n\n\n\n\n<li><strong>401 Unauthorized: <\/strong>invalid or missing token.<\/li>\n\n\n\n\n\n\n<li><strong>404 Not Found: <\/strong>tenant not found. Example message code 0: \u201cTenant configuration not found.\u201d<\/li>\n\n\n\n\n\n\n<li><strong>500 Internal Server Error: <\/strong>unexpected server error.<\/li>\n<\/ul>\n\n\n\n\n\n\n<p><strong>Notes<\/strong>: All requests must use HTTPS. Tokens expire (see expires_in) and must be refreshed when expired. If a token is compromised, it can be revoked by the API provider<\/p>\n\n\n\n\n\n\n\n\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>En tant que d\u00e9veloppeur int\u00e9grant votre syst\u00e8me avec Mapal OS, vous pouvez r\u00e9cup\u00e9rer de mani\u00e8re s\u00e9curis\u00e9e les donn\u00e9es de ventes et de caisse au niveau du shift afin de pouvoir rapprocher les op\u00e9rations de caisse avec les enregistrements Mapal en temps r\u00e9el. L'API Cashrec est RESTful et s\u00e9curis\u00e9e avec HTTPS et JWT.<\/p>\n","protected":false},"author":251210541,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[132553,132552],"tags":[],"class_list":["post-12326","post","type-post","status-publish","format-standard","hentry","category-commencer-2","category-cashrec-4"],"acf":{"article_type":"default","post_id":"","post_url_text":"","post_url":"","info_box":{"title":"","info":""},"post_video":"","import_category":"","overview_item":null,"troubleshoot_case":null},"_links":{"self":[{"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/posts\/12326","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/users\/251210541"}],"replies":[{"embeddable":true,"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/comments?post=12326"}],"version-history":[{"count":0,"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/posts\/12326\/revisions"}],"wp:attachment":[{"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/media?parent=12326"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/categories?post=12326"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/help.mapal-os.com\/fr\/wp-json\/wp\/v2\/tags?post=12326"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}