{"__v":0,"_id":"57bb7aec5c849b1700f1e5c0","category":{"__v":16,"_id":"55650b9fb893840d00444702","pages":["55650b9fb893840d00444704","55662e121ec2311900e4c538","55663058f579050d00c3d42d","556633b61ec2311900e4c544","55663419f579050d00c3d43f","55663490979a3c2500bbafa6","5566352a979a3c2500bbafa8","55663578979a3c2500bbafab","556635fd1ec2311900e4c551","5566365a979a3c2500bbafb3","556636daf579050d00c3d448","5568d269c87afd2500e5254c","556b5b46ab693b1900ce1722","556bbee230922f1700ad5e22","5578af9327f77c0d00fe62ce","567328a458c4890d00bb545f"],"project":"55650b9eb893840d004446fe","version":"55650b9eb893840d00444701","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-05-27T00:11:11.144Z","from_sync":false,"order":9999,"slug":"documentation","title":"Documentation"},"parentDoc":null,"project":"55650b9eb893840d004446fe","user":"5564f227f0f70f0d00a9ab20","version":{"__v":2,"_id":"55650b9eb893840d00444701","project":"55650b9eb893840d004446fe","createdAt":"2015-05-27T00:11:10.647Z","releaseDate":"2015-05-27T00:11:10.647Z","categories":["55650b9fb893840d00444702","5566a1557acd550d0075e894"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"updates":[],"next":{"pages":[],"description":""},"createdAt":"2016-08-22T22:21:32.325Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[{"code":"","language":"text"}]},"method":"post","results":{"codes":[{"name":"","code":"[\n  {\n\t\t\"uuid\": \"709c37c7-7198-417b-bc0c-6a2191288379\",\n    \"metadata\": {\n      \"tag\": \"drone\",\n      \"color\": \"blue\"\n    }\n  }\n]","language":"json","status":200}]},"settings":"","auth":"required","params":[{"_id":"5736586c3d00df0e00ef10ff","ref":"","in":"body","required":false,"desc":"Example Parameter","default":"drone","type":"string","name":"type"},{"_id":"5736586c3d00df0e00ef10fe","ref":"","in":"body","required":false,"desc":"Example Parameter","default":"blue","type":"string","name":"color"}],"url":"/search/tokens"},"isReference":false,"order":12,"body":"Search for devices using any property defined on that device. Meshblu also supports MongoDB-style query operators: `$in`, `$exists`, etc.\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"curl -X POST \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'meshblu_auth_uuid: 8109a97e-9c89-428f-806a-ef875ab6baf6' \\\\\\n-H 'meshblu_auth_token: e110a34829db4bb4a307fef2bae7b501' \\\\\\nhttps://meshblu.octoblu.com/search/tokens -d '{\\\"metadata.tag\\\":\\\"drone\\\"}'\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"post\",\n  \"title\": \"X-MESHBLU-PROJECTION\"\n}\n[/block]\n`X-MESHBLU-PROJECTION` allows you to retrieve only the data you want.\n\nExample: Retrieving only the uuid and name\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"curl -X POST \\\\\\n-H 'Content-Type: application/json' \\\\\\n-H 'meshblu_auth_uuid: 8109a97e-9c89-428f-806a-ef875ab6baf6' \\\\\\n-H 'meshblu_auth_token: e110a34829db4bb4a307fef2bae7b501' \\\\\\n-H 'X-MESHBLU-PROJECTION: {\\\"uuid\\\": true, \\\"metadata.tag\\\": true} \\\\\\nhttps://meshblu.octoblu.com/search/tokens -d '{\\\"metadata.tag\\\":\\\"drones\\\"}'\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"[\\n  {\\n    \\\"uuid\\\":\\\"8d4dfa79-358b-464d-9e58-f3cd84d540c3\\\",\\n    \\\"metadata\\\": {\\n      \\\"tag\\\": \\\"oauth\\\"\\n    }\\n  },\\n  {\\n    \\\"uuid\\\":\\\"ff903a54-166e-447c-8981-5ffc8b2e82f9\\\",\\n    \\\"metadata\\\": {\\n      \\\"tag\\\": \\\"oauth\\\"\\n    }\\n  }\\n]\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]","excerpt":"Search for Tokens","slug":"search-tokens","type":"endpoint","title":"Search Tokens"}

postSearch Tokens

Search for Tokens

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Body Params

type:
stringdrone
Example Parameter
color:
stringblue
Example Parameter

Result Format


Documentation

Search for devices using any property defined on that device. Meshblu also supports MongoDB-style query operators: `$in`, `$exists`, etc. [block:code] { "codes": [ { "code": "curl -X POST \\\n-H 'Content-Type: application/json' \\\n-H 'meshblu_auth_uuid: 8109a97e-9c89-428f-806a-ef875ab6baf6' \\\n-H 'meshblu_auth_token: e110a34829db4bb4a307fef2bae7b501' \\\nhttps://meshblu.octoblu.com/search/tokens -d '{\"metadata.tag\":\"drone\"}'", "language": "shell" } ] } [/block] [block:api-header] { "type": "post", "title": "X-MESHBLU-PROJECTION" } [/block] `X-MESHBLU-PROJECTION` allows you to retrieve only the data you want. Example: Retrieving only the uuid and name [block:code] { "codes": [ { "code": "curl -X POST \\\n-H 'Content-Type: application/json' \\\n-H 'meshblu_auth_uuid: 8109a97e-9c89-428f-806a-ef875ab6baf6' \\\n-H 'meshblu_auth_token: e110a34829db4bb4a307fef2bae7b501' \\\n-H 'X-MESHBLU-PROJECTION: {\"uuid\": true, \"metadata.tag\": true} \\\nhttps://meshblu.octoblu.com/search/tokens -d '{\"metadata.tag\":\"drones\"}'", "language": "shell" } ] } [/block] [block:code] { "codes": [ { "code": "[\n {\n \"uuid\":\"8d4dfa79-358b-464d-9e58-f3cd84d540c3\",\n \"metadata\": {\n \"tag\": \"oauth\"\n }\n },\n {\n \"uuid\":\"ff903a54-166e-447c-8981-5ffc8b2e82f9\",\n \"metadata\": {\n \"tag\": \"oauth\"\n }\n }\n]", "language": "json" } ] } [/block]

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}