Client App Config APIs
POSTCreate App Config
- Description
- Allows a client to create an app config to allow a mobile client to customize menu / account screens on the mobile app. This also serves as an update API where in Client either creates a new record or updates an existing record based on the "type" attribute below.
- Request Endpoint
- POST https://<Example api server address>/appconfig/
- Parameters
- None.
- cURL syntax
curl --include \ --request POST \ --header "Content-Type: application/json" \ --data-binary "{ \"type\":\"menu\", \"style\":null, \"items\":[ { \"type\":\"link\", \"target\":\"account\", \"title\":\"My Account\", \"style\":\"white\" }, { \"type\":\"link\", \"target\":\"home\", \"title\":\"Store Home\", \"style\":\"white\" }, { \"type\":\"categories\", \"style\":\"white\" }, { \"type\":\"link\", \"target\":\"casinos\", \"title\":\"Casinos\", \"style\":\"grey\" }, { \"type\":\"link\", \"target\":\"my-apps\", \"title\":\"My Apps\", \"style\":\"grey\" }, { \"type\":\"divider\", \"style\":\"grey\" }, { \"type\":\"link\", \"target\":\"support\", \"title\":\"Help & Support\", \"style\":\"grey\" }, { \"type\":\"link\", \"target\":\"about\", \"title\":\"About Example\", \"style\":\"grey\" } ] }" \ 'https://core.dev.Example.net/api/appconfig/'
- POST body -
"type": "menu"
Headers: Content-Type: application/json
{ "type": "menu", "style": null, "items": [ { "type": "link", "target": "account", "title": "My Account", "style": "white" }, { "type": "link", "target": "home", "title": "Store Home", "style": "white" }, { "type": "categories", "style": "white" }, { "type": "link", "target": "casinos", "title": "Casinos", "style": "grey" }, { "type": "link", "target": "my-apps", "title": "My Apps", "style": "grey" }, { "type": "divider", "style": "grey" }, { "type": "link", "target": "support", "title": "Help & Support", "style": "grey" }, { "type": "link", "target": "about", "title": "About Example", "style": "grey" } ] }
- Response body -
"type": "menu"
Headers: Content-Type: application/json | HTTPS Status Code: 200
{ "data": { "id": "ffb4a9d2-fbcc-4a18-9a61-acb2231c0d7b", "deleted": false, "type": "menu", "style": null, "items": [ { "type": "link", "target": "account", "title": "My Account", "subtitle": null, "style": "white" }, { "type": "link", "target": "home", "title": "Store Home", "subtitle": null, "style": "white" }, { "type": "categories", "target": null, "title": null, "subtitle": null, "style": "white" }, { "type": "link", "target": "casinos", "title": "Casinos", "subtitle": null, "style": "grey" }, { "type": "link", "target": "my-apps", "title": "My Apps", "subtitle": null, "style": "grey" }, { "type": "divider", "target": null, "title": null, "subtitle": null, "style": "grey" }, { "type": "link", "target": "support", "title": "Help & Support", "subtitle": null, "style": "grey" }, { "type": "link", "target": "about", "title": "About Example", "subtitle": null, "style": "grey" } ] }, "detail": null, "error": false, "message": "Saving app config data successful" }
- POST body - "type": "account"
Headers: Content-Type: application/json
{ "style": null, "type": "account", "items": [ { "type": "link", "target": "account-info", "title": "Account Information", "subtitle": "Change your PIN and edit account details", "style": "white" }, { "type": "link", "target": "payment-methods", "title": "Payment Methods", "subtitle": "Add and edit your payment methods", "style": "white" }, { "type": "link", "target": "promo-codes", "title": "Example Promo Codes", "subtitle": "Add codes and promo history", "style": "white" }, { "type": "link", "target": "transactions", "title": "Transaction History", "subtitle": "View all deposits and withdrawals", "style": "white" }, { "type": "link", "target": "settings", "title": "Settings", "subtitle": "Manage notification preferences and more", "style": "white" }, { "type": "link", "target": "logout", "title": "Log Out", "subtitle": "", "style": "white" } ] }
- Response body - "type": "account"
Headers: Content-Type: application/json | HTTPS Status Code: 200
{ "data": { "id": "4de30546-e000-4c59-904f-9078ba32dcea", "deleted": false, "type": "account", "style": null, "items": [ { "type": "link", "target": "account-info", "title": "Account Information", "subtitle": "Change your PIN and edit account details", "style": "white" }, { "type": "link", "target": "payment-methods", "title": "Payment Methods", "subtitle": "Add and edit your payment methods", "style": "white" }, { "type": "link", "target": "promo-codes", "title": "Example Promo Codes", "subtitle": "Add codes and promo history", "style": "white" }, { "type": "link", "target": "transactions", "title": "Transaction History", "subtitle": "View all deposits and withdrawals", "style": "white" }, { "type": "link", "target": "settings", "title": "Settings", "subtitle": "Manage notification preferences and more", "style": "white" }, { "type": "link", "target": "logout", "title": "Log Out", "subtitle": "", "style": "white" } ] }, "detail": null, "error": false, "message": "Saving app config data successful" }
GETFetch All App Config
- Description
- Allows a client to fetch all the records for app config with pagination support.
- Request Endpoint
- GET https://<Example api server address>/appconfig/
- Parameters
Parameter Type Use Description offset Number Optional Offset of the data set. limit Number Optional Limit of the data set. - cURL syntax
curl --include \ 'https://core.dev.Example.net/api/appconfig/'
- Response body
Headers: Content-Type: application/json | HTTPS Status Code: 200
{ "data": { "content": [ { "id": "ffb4a9d2-fbcc-4a18-9a61-acb2231c0d7b", "deleted": false, "type": "menu", "style": null, "items": [ { "type": "link", "target": "account", "title": "My Account", "subtitle": null, "style": "white" }, { "type": "link", "target": "home", "title": "Store Home", "subtitle": null, "style": "white" }, { "type": "categories", "target": null, "title": null, "subtitle": null, "style": "white" }, { "type": "link", "target": "casinos", "title": "Casinos", "subtitle": null, "style": "grey" }, { "type": "link", "target": "my-apps", "title": "My Apps", "subtitle": null, "style": "grey" }, { "type": "divider", "target": null, "title": null, "subtitle": null, "style": "grey" }, { "type": "link", "target": "support", "title": "Help & Support", "subtitle": null, "style": "grey" }, { "type": "link", "target": "about", "title": "About Example", "subtitle": null, "style": "grey" } ] }, { "id": "4de30546-e000-4c59-904f-9078ba32dcea", "deleted": false, "type": "account", "style": null, "items": [ { "type": "link", "target": "account-info", "title": "Account Information", "subtitle": "Change your PIN and edit account details", "style": "white" }, { "type": "link", "target": "payment-methods", "title": "Payment Methods", "subtitle": "Add and edit your payment methods", "style": "white" }, { "type": "link", "target": "promo-codes", "title": "Example Promo Codes", "subtitle": "Add codes and promo history", "style": "white" }, { "type": "link", "target": "transactions", "title": "Transaction History", "subtitle": "View all deposits and withdrawals", "style": "white" }, { "type": "link", "target": "settings", "title": "Settings", "subtitle": "Manage notification preferences and more", "style": "white" }, { "type": "link", "target": "logout", "title": "Log Out", "subtitle": "", "style": "white" } ] } ], "totalPages": 1, "totalElements": 2, "last": true, "size": 70, "number": 0, "sort": null, "first": true, "numberOfElements": 2 }, "detail": null, "error": false, "message": "Fetching all app config data successful" }
GETFetch App Config By Type
- Description
- Allows a client to fetch an app config by type.
- Request Endpoint
- GET https://<Example api server address>/appconfig/type/{type}
- Parameters
Parameter Type Use Description type String Required The type of app config used to fetch the data. - cURL syntax
curl --include \ 'https://core.dev.Example.net/api/appconfig/type/type'
- Response body
Headers: Content-Type: application/json | HTTPS Status Code: 200
{ "data": { "id": "ffb4a9d2-fbcc-4a18-9a61-acb2231c0d7b", "deleted": false, "type": "menu", "style": null, "items": [ { "type": "link", "target": "account", "title": "My Account", "subtitle": null, "style": "white" }, { "type": "link", "target": "home", "title": "Store Home", "subtitle": null, "style": "white" }, { "type": "categories", "target": null, "title": null, "subtitle": null, "style": "white" }, { "type": "link", "target": "casinos", "title": "Casinos", "subtitle": null, "style": "grey" }, { "type": "link", "target": "my-apps", "title": "My Apps", "subtitle": null, "style": "grey" }, { "type": "divider", "target": null, "title": null, "subtitle": null, "style": "grey" }, { "type": "link", "target": "support", "title": "Help & Support", "subtitle": null, "style": "grey" }, { "type": "link", "target": "about", "title": "About Example", "subtitle": null, "style": "grey" } ] }, "detail": null, "error": false, "message": "Fetching app config data by type successful" }
GETFetch Full App Config
- Description
- Allows a client to fetch all app config in a key value pair format (with the type of record acting as the key) unlike the above API which is array based. There is no pagination support for this for obvious reasons.
- Request Endpoint
- GET https://<Example api server address>/appconfig/full
- Parameters
- None.
- cURL syntax
curl --include \ 'https://core.dev.Example.net/api/appconfig/full'
- Response body
Headers: Content-Type: application/json | HTTPS Status Code: 200
{ "data": { "menu": { "id": "ffb4a9d2-fbcc-4a18-9a61-acb2231c0d7b", "deleted": false, "type": "menu", "style": null, "items": [ { "type": "link", "target": "account", "title": "My Account", "subtitle": null, "style": "white" }, { "type": "link", "target": "home", "title": "Store Home", "subtitle": null, "style": "white" }, { "type": "categories", "target": null, "title": null, "subtitle": null, "style": "white" }, { "type": "link", "target": "casinos", "title": "Casinos", "subtitle": null, "style": "grey" }, { "type": "link", "target": "my-apps", "title": "My Apps", "subtitle": null, "style": "grey" }, { "type": "divider", "target": null, "title": null, "subtitle": null, "style": "grey" }, { "type": "link", "target": "support", "title": "Help & Support", "subtitle": null, "style": "grey" }, { "type": "link", "target": "about", "title": "About Example", "subtitle": null, "style": "grey" } ] }, "account": { "id": "4de30546-e000-4c59-904f-9078ba32dcea", "deleted": false, "type": "account", "style": null, "items": [ { "type": "link", "target": "account-info", "title": "Account Information", "subtitle": "Change your PIN and edit account details", "style": "white" }, { "type": "link", "target": "payment-methods", "title": "Payment Methods", "subtitle": "Add and edit your payment methods", "style": "white" }, { "type": "link", "target": "promo-codes", "title": "Example Promo Codes", "subtitle": "Add codes and promo history", "style": "white" }, { "type": "link", "target": "transactions", "title": "Transaction History", "subtitle": "View all deposits and withdrawals", "style": "white" }, { "type": "link", "target": "settings", "title": "Settings", "subtitle": "Manage notification preferences and more", "style": "white" }, { "type": "link", "target": "logout", "title": "Log Out", "subtitle": "", "style": "white" } ] } }, "detail": null, "error": false, "message": "Fetching full app config data successful" }