Objective-C / New FreshBooks / Create Expense with Receipt
Back to Collection Items
#import <CkoHttp.h>
#import <CkoJsonObject.h>
#import <CkoHttpResponse.h>
#import <CkoStringBuilder.h>
#import <NSString.h>
// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.
CkoHttp *http = [[CkoHttp alloc] init];
BOOL success;
// Use this online tool to generate code from sample JSON: Generate Code to Create JSON
// The following JSON is sent in the request body.
// {
// "expense": {
// "transactionid": null,
// "status": null,
// "has_receipt": false,
// "always_remember": false,
// "is_cogs": false,
// "account_name": null,
// "include_receipt": false,
// "amount": {
// "amount": "79.73",
// "code": "USD"
// },
// "notes": "Purchased Gasoline for deliveries",
// "vendor": "Shell Gas Station",
// "date": "2019-04-24",
// "staffid": 1,
// "author_name": null,
// "taxName1": "other tax",
// "taxName2": null,
// "taxAmount1": {
// "amount": "9.17",
// "code": "USD"
// },
// "taxPercent1": 13,
// "taxPercent2": null,
// "markup_percent": null,
// "invoiceid": null,
// "attachment": {
// "jwt": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA",
// "media_type": "image/png",
// "expenseid": null
// },
// "categoryid": "2003174",
// "clientid": null
// }
// }
CkoJsonObject *json = [[CkoJsonObject alloc] init];
[json UpdateNull: @"expense.transactionid"];
[json UpdateNull: @"expense.status"];
[json UpdateBool: @"expense.has_receipt" value: NO];
[json UpdateBool: @"expense.always_remember" value: NO];
[json UpdateBool: @"expense.is_cogs" value: NO];
[json UpdateNull: @"expense.account_name"];
[json UpdateBool: @"expense.include_receipt" value: NO];
[json UpdateString: @"expense.amount.amount" value: @"79.73"];
[json UpdateString: @"expense.amount.code" value: @"USD"];
[json UpdateString: @"expense.notes" value: @"Purchased Gasoline for deliveries"];
[json UpdateString: @"expense.vendor" value: @"Shell Gas Station"];
[json UpdateString: @"expense.date" value: @"2019-04-24"];
[json UpdateInt: @"expense.staffid" value: [NSNumber numberWithInt: 1]];
[json UpdateNull: @"expense.author_name"];
[json UpdateString: @"expense.taxName1" value: @"other tax"];
[json UpdateNull: @"expense.taxName2"];
[json UpdateString: @"expense.taxAmount1.amount" value: @"9.17"];
[json UpdateString: @"expense.taxAmount1.code" value: @"USD"];
[json UpdateInt: @"expense.taxPercent1" value: [NSNumber numberWithInt: 13]];
[json UpdateNull: @"expense.taxPercent2"];
[json UpdateNull: @"expense.markup_percent"];
[json UpdateNull: @"expense.invoiceid"];
[json UpdateString: @"expense.attachment.jwt" value: @"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA"];
[json UpdateString: @"expense.attachment.media_type" value: @"image/png"];
[json UpdateNull: @"expense.attachment.expenseid"];
[json UpdateString: @"expense.categoryid" value: @"2003174"];
[json UpdateNull: @"expense.clientid"];
// Adds the "Authorization: Bearer <access_token>" header.
http.AuthToken = @"<access_token>";
[http SetRequestHeader: @"Content-Type" value: @"application/json"];
CkoHttpResponse *resp = [http PostJson3: @"https://api.freshbooks.com/accounting/account/{{accountId}}/expenses/expenses?include%5B%5D=attachment" contentType: @"application/json" json: json];
if (http.LastMethodSuccess == NO) {
NSLog(@"%@",http.LastErrorText);
return;
}
CkoStringBuilder *sbResponseBody = [[CkoStringBuilder alloc] init];
[resp GetBodySb: sbResponseBody];
CkoJsonObject *jResp = [[CkoJsonObject alloc] init];
[jResp LoadSb: sbResponseBody];
jResp.EmitCompact = NO;
NSLog(@"%@",@"Response Body:");
NSLog(@"%@",[jResp Emit]);
int respStatusCode = [resp.StatusCode intValue];
NSLog(@"%@%d",@"Response Status Code = ",respStatusCode);
if (respStatusCode >= 400) {
NSLog(@"%@",@"Response Header:");
NSLog(@"%@",resp.Header);
NSLog(@"%@",@"Failed.");
return;
}
// Sample JSON response:
// (Sample code for parsing the JSON response is shown below)
// {
// "response": {
// "result": {
// "expense": {
// "account_name": "",
// "accountid": null,
// "accounting_systemid": "wkMd2g",
// "amount": {
// "amount": "79.73",
// "code": "USD"
// },
// "attachment": {
// "attachmentid": 8670,
// "id": 8670,
// "jwt": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA",
// "media_type": "image/png"
// },
// "background_jobid": null,
// "bank_name": "",
// "categoryid": 2003174,
// "clientid": 0,
// "compounded_tax": false,
// "date": "2019-04-24",
// "expenseid": 1825574,
// "ext_invoiceid": 0,
// "ext_systemid": 0,
// "from_bulk_import": false,
// "has_receipt": true,
// "id": 1825574,
// "include_receipt": false,
// "invoiceid": null,
// "is_cogs": false,
// "isduplicate": true,
// "markup_percent": "0",
// "notes": "Purchased Gasoline for deliveries",
// "profileid": null,
// "projectid": 0,
// "staffid": 1,
// "status": 0,
// "taxAmount1": {
// "amount": "9.17",
// "code": "USD"
// },
// "taxAmount2": null,
// "taxName1": "other tax",
// "taxName2": null,
// "taxPercent1": "13",
// "taxPercent2": null,
// "transactionid": null,
// "updated": "2019-04-24 11:33:35",
// "vendor": "Shell Gas Station",
// "vis_state": 0
// }
// }
// }
// }
// Sample code for parsing the JSON response...
// Use this online tool to generate parsing code from sample JSON: Generate JSON Parsing Code
NSString *Account_name = [jResp StringOf: @"response.result.expense.account_name"];
NSString *Accountid = [jResp StringOf: @"response.result.expense.accountid"];
NSString *Accounting_systemid = [jResp StringOf: @"response.result.expense.accounting_systemid"];
NSString *Amount = [jResp StringOf: @"response.result.expense.amount.amount"];
NSString *Code = [jResp StringOf: @"response.result.expense.amount.code"];
int Attachmentid = [[jResp IntOf: @"response.result.expense.attachment.attachmentid"] intValue];
int Id = [[jResp IntOf: @"response.result.expense.attachment.id"] intValue];
NSString *v_Jwt = [jResp StringOf: @"response.result.expense.attachment.jwt"];
NSString *Media_type = [jResp StringOf: @"response.result.expense.attachment.media_type"];
NSString *Background_jobid = [jResp StringOf: @"response.result.expense.background_jobid"];
NSString *Bank_name = [jResp StringOf: @"response.result.expense.bank_name"];
int Categoryid = [[jResp IntOf: @"response.result.expense.categoryid"] intValue];
int Clientid = [[jResp IntOf: @"response.result.expense.clientid"] intValue];
BOOL Compounded_tax = [jResp BoolOf: @"response.result.expense.compounded_tax"];
NSString *Date = [jResp StringOf: @"response.result.expense.date"];
int Expenseid = [[jResp IntOf: @"response.result.expense.expenseid"] intValue];
int Ext_invoiceid = [[jResp IntOf: @"response.result.expense.ext_invoiceid"] intValue];
int Ext_systemid = [[jResp IntOf: @"response.result.expense.ext_systemid"] intValue];
BOOL From_bulk_import = [jResp BoolOf: @"response.result.expense.from_bulk_import"];
BOOL Has_receipt = [jResp BoolOf: @"response.result.expense.has_receipt"];
int ExpenseId = [[jResp IntOf: @"response.result.expense.id"] intValue];
BOOL Include_receipt = [jResp BoolOf: @"response.result.expense.include_receipt"];
NSString *Invoiceid = [jResp StringOf: @"response.result.expense.invoiceid"];
BOOL Is_cogs = [jResp BoolOf: @"response.result.expense.is_cogs"];
BOOL Isduplicate = [jResp BoolOf: @"response.result.expense.isduplicate"];
NSString *Markup_percent = [jResp StringOf: @"response.result.expense.markup_percent"];
NSString *Notes = [jResp StringOf: @"response.result.expense.notes"];
NSString *Profileid = [jResp StringOf: @"response.result.expense.profileid"];
int Projectid = [[jResp IntOf: @"response.result.expense.projectid"] intValue];
int Staffid = [[jResp IntOf: @"response.result.expense.staffid"] intValue];
int Status = [[jResp IntOf: @"response.result.expense.status"] intValue];
NSString *TaxAmount1Amount = [jResp StringOf: @"response.result.expense.taxAmount1.amount"];
NSString *TaxAmount1Code = [jResp StringOf: @"response.result.expense.taxAmount1.code"];
NSString *TaxAmount2 = [jResp StringOf: @"response.result.expense.taxAmount2"];
NSString *TaxName1 = [jResp StringOf: @"response.result.expense.taxName1"];
NSString *TaxName2 = [jResp StringOf: @"response.result.expense.taxName2"];
NSString *TaxPercent1 = [jResp StringOf: @"response.result.expense.taxPercent1"];
NSString *TaxPercent2 = [jResp StringOf: @"response.result.expense.taxPercent2"];
NSString *Transactionid = [jResp StringOf: @"response.result.expense.transactionid"];
NSString *Updated = [jResp StringOf: @"response.result.expense.updated"];
NSString *Vendor = [jResp StringOf: @"response.result.expense.vendor"];
int Vis_state = [[jResp IntOf: @"response.result.expense.vis_state"] intValue];
Curl Command
curl -X POST
-H "Authorization: Bearer <access_token>"
-H "Content-Type: application/json"
-d '{
"expense": {
"transactionid": null,
"status": null,
"has_receipt": false,
"always_remember": false,
"is_cogs": false,
"account_name": null,
"include_receipt": false,
"amount": {
"amount": "79.73",
"code": "USD"
},
"notes": "Purchased Gasoline for deliveries",
"vendor": "Shell Gas Station",
"date": "2019-04-24",
"staffid": 1,
"author_name": null,
"taxName1": "other tax",
"taxName2": null,
"taxAmount1": {
"amount": "9.17",
"code": "USD"
},
"taxPercent1": 13,
"taxPercent2": null,
"markup_percent": null,
"invoiceid": null,
"attachment": {
"jwt": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA",
"media_type": "image/png",
"expenseid": null
},
"categoryid": "2003174",
"clientid": null
}
}'
https://api.freshbooks.com/accounting/account/{{accountId}}/expenses/expenses?include%5B%5D=attachment
Postman Collection Item JSON
{
"name": "Create Expense with Receipt",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"name": "Content-Type",
"value": "application/json",
"type": "text"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"expense\": {\n \"transactionid\": null,\n \"status\": null,\n \"has_receipt\": false,\n \"always_remember\": false,\n \"is_cogs\": false,\n \"account_name\": null,\n \"include_receipt\": false,\n \"amount\": {\n \"amount\": \"79.73\",\n \"code\": \"USD\"\n },\n \"notes\": \"Purchased Gasoline for deliveries\",\n \"vendor\": \"Shell Gas Station\",\n \"date\": \"2019-04-24\",\n \"staffid\": 1,\n \"author_name\": null,\n \"taxName1\": \"other tax\",\n \"taxName2\": null,\n \"taxAmount1\": {\n \"amount\": \"9.17\",\n \"code\": \"USD\"\n },\n \"taxPercent1\": 13,\n \"taxPercent2\": null,\n \"markup_percent\": null,\n \"invoiceid\": null,\n \"attachment\": {\n \"jwt\": \"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA\",\n \"media_type\": \"image/png\",\n \"expenseid\": null\n },\n \"categoryid\": \"2003174\",\n \"clientid\": null\n }\n}"
},
"url": {
"raw": "https://api.freshbooks.com/accounting/account/{{accountId}}/expenses/expenses?include%5B%5D=attachment",
"protocol": "https",
"host": [
"api",
"freshbooks",
"com"
],
"path": [
"accounting",
"account",
"{{accountId}}",
"expenses",
"expenses"
],
"query": [
{
"key": "include%5B%5D",
"value": "attachment"
}
]
},
"description": "In order to create an expense with a receipt, you will first need to upload your image via the uploader endpoint. Once you receive a response, you can apply that `jwt` token to your expense under the nested `attachment` object. Look at the example on the right. "
},
"response": [
{
"name": "Create Expense",
"originalRequest": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"name": "Content-Type",
"value": "application/json",
"type": "text"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"expense\": {\n \"transactionid\": null,\n \"status\": null,\n \"has_receipt\": false,\n \"always_remember\": false,\n \"is_cogs\": false,\n \"account_name\": null,\n \"include_receipt\": false,\n \"amount\": {\n \"amount\": \"79.73\",\n \"code\": \"USD\"\n },\n \"notes\": \"Purchased Gasoline for deliveries\",\n \"vendor\": \"Shell Gas Station\",\n \"date\": \"2019-04-24\",\n \"staffid\": 1,\n \"author_name\": null,\n \"taxName1\": \"other tax\",\n \"taxName2\": null,\n \"taxAmount1\": {\n \"amount\": \"9.17\",\n \"code\": \"USD\"\n },\n \"taxPercent1\": 13,\n \"taxPercent2\": null,\n \"markup_percent\": null,\n \"invoiceid\": null,\n \"attachment\": {\n \"jwt\": \"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA\",\n \"media_type\": \"image/png\",\n \"expenseid\": null\n },\n \"categoryid\": \"2003174\",\n \"clientid\": null\n }\n}"
},
"url": {
"raw": "https://api.freshbooks.com/accounting/account/{{accountId}}/expenses/expenses?include%5B%5D=attachment",
"protocol": "https",
"host": [
"api",
"freshbooks",
"com"
],
"path": [
"accounting",
"account",
"{{accountId}}",
"expenses",
"expenses"
],
"query": [
{
"key": "include%5B%5D",
"value": "attachment"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Server",
"value": "nginx"
},
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "X-NewRelic-App-Data",
"value": "PxQBWV5TCBABVlVSAwEOVlcTGhE1AwE2QgNWEVlbQFtcCxYnRA9QFg1ZWU4DFVdfRgFPCkNFR0gBSUZWDBUGEQoHQBJdVkdXQEcVUR1RHVBVBQBZU1UMCwNQVFsDBgVRSAAFBVBKQVFWUwEACAkBCgJcCFQBAAtASFBWDRUGZQ=="
},
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "Expires",
"value": "Tue, 24 Apr 2018 15:33:35 GMT"
},
{
"key": "Cache-Control",
"value": "no-cache"
},
{
"key": "Content-Encoding",
"value": "gzip"
},
{
"key": "Via",
"value": "1.1 google"
},
{
"key": "Via",
"value": "1.1 varnish"
},
{
"key": "Transfer-Encoding",
"value": "chunked"
},
{
"key": "Accept-Ranges",
"value": "bytes"
},
{
"key": "Date",
"value": "Wed, 24 Apr 2019 15:33:35 GMT"
},
{
"key": "Connection",
"value": "keep-alive"
},
{
"key": "X-Served-By",
"value": "cache-jfk8129-JFK"
},
{
"key": "X-Cache",
"value": "MISS"
},
{
"key": "X-Cache-Hits",
"value": "0"
},
{
"key": "Vary",
"value": "Accept-Encoding"
},
{
"key": "Country",
"value": "CA"
},
{
"key": "Strict-Transport-Security",
"value": "max-age=31536000; includeSubDomains; preload"
}
],
"cookie": [
],
"body": "{\n \"response\": {\n \"result\": {\n \"expense\": {\n \"account_name\": \"\",\n \"accountid\": null,\n \"accounting_systemid\": \"wkMd2g\",\n \"amount\": {\n \"amount\": \"79.73\",\n \"code\": \"USD\"\n },\n \"attachment\": {\n \"attachmentid\": 8670,\n \"id\": 8670,\n \"jwt\": \"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY2NvdW50Ijo0MjM2NDEwLCJvcmlnaW5hbF9maWxlbmFtZSI6IlNjcmVlbiBTaG90IDIwMTktMDQtMjQgYXQgOS4zOS4xOSBBTS5wbmciLCJidWNrZXQiOiJ1cGxvYWRzIiwiZmlsZW5hbWUiOiJ1cGxvYWQtMGU2ZDMwOWQ1ZTI5MzA3NmNhMGIyNDdkODFlOGJlNWE4NDZlZWE0YSIsImxlbmd0aCI6MTkxNDcyLCJrZXkiOiInZG9jcy0nLTQyMzY0MTAvdXBsb2FkLTBlNmQzMDlkNWUyOTMwNzZjYTBiMjQ3ZDgxZThiZTVhODQ2ZWVhNGEifQ.SOoW3_nTUrxjYO76g1UXHPIrO_aLbTpXCHEa-ZcnejA\",\n \"media_type\": \"image/png\"\n },\n \"background_jobid\": null,\n \"bank_name\": \"\",\n \"categoryid\": 2003174,\n \"clientid\": 0,\n \"compounded_tax\": false,\n \"date\": \"2019-04-24\",\n \"expenseid\": 1825574,\n \"ext_invoiceid\": 0,\n \"ext_systemid\": 0,\n \"from_bulk_import\": false,\n \"has_receipt\": true,\n \"id\": 1825574,\n \"include_receipt\": false,\n \"invoiceid\": null,\n \"is_cogs\": false,\n \"isduplicate\": true,\n \"markup_percent\": \"0\",\n \"notes\": \"Purchased Gasoline for deliveries\",\n \"profileid\": null,\n \"projectid\": 0,\n \"staffid\": 1,\n \"status\": 0,\n \"taxAmount1\": {\n \"amount\": \"9.17\",\n \"code\": \"USD\"\n },\n \"taxAmount2\": null,\n \"taxName1\": \"other tax\",\n \"taxName2\": null,\n \"taxPercent1\": \"13\",\n \"taxPercent2\": null,\n \"transactionid\": null,\n \"updated\": \"2019-04-24 11:33:35\",\n \"vendor\": \"Shell Gas Station\",\n \"vis_state\": 0\n }\n }\n }\n}"
}
]
}