{"metadata":{"image":[],"title":"","description":""},"api":{"url":"","auth":"required","settings":"","results":{"codes":[]},"params":[],"examples":{"codes":[]},"method":"put"},"next":{"description":"","pages":[]},"title":"Update Custom Report","type":"endpoint","slug":"update-custom-report","excerpt":"","body":"## Definition\nhttps<span>://sandbox.bluesnap.com/services/2/report/dynamic-def/{report ID}</span>\n\n<hr>\n\n## Documentation\nThis request allows you to update an existing custom report. \n\n### Request Content\nEnter the report's ID in the request URL, as follows:\n\n`services/2/report/dynamic-def/{report ID}`\n\nFor example: `services/2/report/dynamic-def/12141`\n\nIn the request body, send a **[customReport](doc:custom-report-object)** object, with the following:  \n\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`id` &nbsp;&nbsp;&nbsp; *integer* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`title` &nbsp;&nbsp;&nbsp; *string* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`info` &nbsp;&nbsp;&nbsp; *string* &nbsp;&nbsp;&nbsp;optional\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`category` &nbsp;&nbsp;&nbsp; *string* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`columns` &nbsp;&nbsp;&nbsp; *array* &nbsp;&nbsp;&nbsp;<span style=\"color:#F37500\">**required**</span>\n\n### Response Details \nIf successful, the response HTTP status code is 200 OK.\nThe response body contains the **[customReport](doc:custom-report-object)** object. \n\n<hr>\n\n## Examples \n### Request Examples \n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"curl -v -X PUT https://sandbox.bluesnap.com/services/2/report/dynamic-def/7637 \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'Accept: application/json' \\\\ \\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n{\\n  \\\"id\\\": 7637,\\n  \\\"category\\\": \\\"TransactionCategory\\\",\\n  \\\"title\\\": \\\"Transaction Report 1\\\",\\n  \\\"info\\\": \\\"My custom transaction report\\\",\\n  \\\"columns\\\": [\\n    {\\n      \\\"name\\\": \\\"Merchant Sales (Auth Currency)\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Auth. Currency\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Merchant Transaction ID\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Transaction Date\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Transaction Type\\\"\\n    }\\n  ]\\n}'\",\n      \"language\": \"curl\",\n      \"name\": \"Update Custom Report\"\n    }\n  ]\n}\n[/block]\n### Reponse Examples\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n  \\\"id\\\": 7637,\\n  \\\"category\\\": \\\"TransactionCategory\\\",\\n  \\\"title\\\": \\\"Transaction Report 1\\\",\\n  \\\"info\\\": \\\"My custom transaction report\\\",\\n  \\\"columns\\\": [\\n    {\\n      \\\"name\\\": \\\"Merchant Sales (Auth Currency)\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Auth. Currency\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Merchant Transaction ID\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Transaction Date\\\"\\n    },\\n    {\\n      \\\"name\\\": \\\"Transaction Type\\\"\\n    }\\n  ]\\n}\",\n      \"language\": \"json\",\n      \"name\": \"Response\"\n    }\n  ]\n}\n[/block]\n<hr>\n\n## Example Description\n### Update Custom Report \nThis request shows how to update an existing custom report. Include the report's `id` in the request URL, as shown in the example, and include the desired report changes in the body. Please note that if a property is omitted from the request, that property will be removed from the existing report. It is recommended that you first [retrieve the report](doc:retrieve-custom-report), make any updates, and then send the Update Custom Report request.","updates":[],"order":2,"isReference":false,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"603fec227146110018e1daa4","createdAt":"2020-11-03T16:51:09.624Z","user":"5ea72d649148ff00653f6bbc","category":{"sync":{"isSync":false,"url":""},"pages":[],"title":"Custom Reporting API","slug":"dynamic-reporting-api","order":2,"from_sync":false,"reference":false,"_id":"603fec227146110018e1da4f","createdAt":"2020-11-03T16:46:14.694Z","version":"603fec227146110018e1daaf","project":"57336fd5a6a9c40e00e13a0b","__v":0},"version":{"version":"8976-Tools","version_clean":"8976.0.0-Tools","codename":"3.37 Release","is_stable":false,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["603fec227146110018e1da3d","603fec227146110018e1da3e","603fec227146110018e1da3f","603fec227146110018e1da40","603fec227146110018e1da41","603fec227146110018e1da42","603fec227146110018e1da43","603fec227146110018e1da44","603fec227146110018e1da45","603fec227146110018e1da46","603fec227146110018e1da47","603fec227146110018e1da48","5b34c737e0dca2000311de6a","603fec227146110018e1da49","603fec227146110018e1da4a","603fec227146110018e1da4b","603fec227146110018e1da4c","603fec227146110018e1da4d","603fec227146110018e1da4e","603fec227146110018e1da4f"],"_id":"603fec227146110018e1daaf","project":"57336fd5a6a9c40e00e13a0b","__v":0,"forked_from":"6019bc72944282005e966fd4","createdAt":"2018-04-23T15:17:35.680Z","releaseDate":"2018-04-23T15:17:35.680Z"},"project":"57336fd5a6a9c40e00e13a0b","__v":0,"parentDoc":null}

putUpdate Custom Report


Definition

https://sandbox.bluesnap.com/services/2/report/dynamic-def/{report ID}


Documentation

This request allows you to update an existing custom report.

Request Content

Enter the report's ID in the request URL, as follows:

services/2/report/dynamic-def/{report ID}

For example: services/2/report/dynamic-def/12141

In the request body, send a customReport object, with the following:

      id     integer    required
      title     string    required
      info     string    optional
      category     string    required
      columns     array    required

Response Details

If successful, the response HTTP status code is 200 OK.
The response body contains the customReport object.


Examples

Request Examples

curl -v -X PUT https://sandbox.bluesnap.com/services/2/report/dynamic-def/7637 \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \ 
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
{
  "id": 7637,
  "category": "TransactionCategory",
  "title": "Transaction Report 1",
  "info": "My custom transaction report",
  "columns": [
    {
      "name": "Merchant Sales (Auth Currency)"
    },
    {
      "name": "Auth. Currency"
    },
    {
      "name": "Merchant Transaction ID"
    },
    {
      "name": "Transaction Date"
    },
    {
      "name": "Transaction Type"
    }
  ]
}'

Reponse Examples

{
  "id": 7637,
  "category": "TransactionCategory",
  "title": "Transaction Report 1",
  "info": "My custom transaction report",
  "columns": [
    {
      "name": "Merchant Sales (Auth Currency)"
    },
    {
      "name": "Auth. Currency"
    },
    {
      "name": "Merchant Transaction ID"
    },
    {
      "name": "Transaction Date"
    },
    {
      "name": "Transaction Type"
    }
  ]
}


Example Description

Update Custom Report

This request shows how to update an existing custom report. Include the report's id in the request URL, as shown in the example, and include the desired report changes in the body. Please note that if a property is omitted from the request, that property will be removed from the existing report. It is recommended that you first retrieve the report, make any updates, and then send the Update Custom Report request.