{"_id":"55b9568ae512530d00a1b4c1","project":"54295508cd35120800fceca2","user":"542954f6cd35120800fceca0","__v":5,"category":{"_id":"55b9566ce536930d00e360a7","pages":["55b95680e512530d00a1b4bf","55b9568ae512530d00a1b4c1"],"project":"54295508cd35120800fceca2","version":"54295508cd35120800fceca5","__v":2,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-07-29T22:40:44.562Z","from_sync":false,"order":1,"slug":"authentication","title":"Authentication"},"version":{"_id":"54295508cd35120800fceca5","project":"54295508cd35120800fceca2","__v":9,"createdAt":"2014-09-29T12:48:08.901Z","releaseDate":"2014-09-29T12:48:08.901Z","categories":["54295508cd35120800fceca6","5429e1307d3ab608001b0f14","543c975b1e6ad61400b04c79","543c976a1e6ad61400b04c7a","55b874fa8ea8d50d00922a1a","55b953a6b42b610d00c9b266","55b953b5e536930d00e36095","55b9566ce536930d00e360a7","55b95f28e512530d00a1b4d7"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":false,"codename":"","version_clean":"1.0.0","version":"1.0"},"githubsync":"","updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-07-29T22:41:14.550Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"settings":"","results":{"codes":[]},"auth":"required","params":[],"url":""},"isReference":false,"order":0,"body":"[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"What is an API Token?\"\n}\n[/block]\nAn API Token is a string that let's you perform actions directly on the API as the account linked to that token.\nIt looks something like: \"1b61610b-6d09-420f-9562-552dbf5512af\"\nIt should be stored in a safe place. Anyone who has a token, can perform any action for the corresponding account.\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"When do I use an API Token?\"\n}\n[/block]\nYou use an API Token when you want to create a Yo account that you own via code.\nIf you want to create a Yo client that allows other people to send Yos then check out OAuth \n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"How do I create an account and get its API Token?\"\n}\n[/block]\nLet's start by logging in to https://dev.justyo.co (here we use our personal Yo account credentials)\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/mjdnOsO4QF9Sak02UUEo_Screen%20Shot%202015-07-29%20at%203.43.53%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.43.53 PM.png\",\n        \"1010\",\n        \"721\",\n        \"#843c9c\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\nOr signing up if we don't have a Yo account\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/YiSTKju7RjKPQbdgoh1i_Screen%20Shot%202015-07-29%20at%203.45.04%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.45.04 PM.png\",\n        \"1010\",\n        \"744\",\n        \"#8c44a4\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/d8s3BsMRVOzh7fGYpYjX_Screen%20Shot%202015-07-29%20at%203.45.34%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.45.34 PM.png\",\n        \"1010\",\n        \"744\",\n        \"#4a627b\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/nHtKu76SR9yMztLcvEWB_Screen%20Shot%202015-07-29%20at%203.46.46%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.46.46 PM.png\",\n        \"1010\",\n        \"744\",\n        \"#4b6179\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/ewfVnYo9QsO6SMb6qNnM_Screen%20Shot%202015-07-29%20at%203.46.53%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.46.53 PM.png\",\n        \"1010\",\n        \"744\",\n        \"#54687f\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/jCly135lSnWXP6Rq2avn_Screen%20Shot%202015-07-29%20at%203.47.31%20PM.png\",\n        \"Screen Shot 2015-07-29 at 3.47.31 PM.png\",\n        \"1010\",\n        \"744\",\n        \"#496078\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]","excerpt":"What are they? When do I use them?","slug":"api-tokens","type":"basic","title":"API Tokens"}

API Tokens

What are they? When do I use them?

[block:api-header] { "type": "basic", "title": "What is an API Token?" } [/block] An API Token is a string that let's you perform actions directly on the API as the account linked to that token. It looks something like: "1b61610b-6d09-420f-9562-552dbf5512af" It should be stored in a safe place. Anyone who has a token, can perform any action for the corresponding account. [block:api-header] { "type": "basic", "title": "When do I use an API Token?" } [/block] You use an API Token when you want to create a Yo account that you own via code. If you want to create a Yo client that allows other people to send Yos then check out OAuth [block:api-header] { "type": "basic", "title": "How do I create an account and get its API Token?" } [/block] Let's start by logging in to https://dev.justyo.co (here we use our personal Yo account credentials) [block:image] { "images": [ { "image": [ "https://files.readme.io/mjdnOsO4QF9Sak02UUEo_Screen%20Shot%202015-07-29%20at%203.43.53%20PM.png", "Screen Shot 2015-07-29 at 3.43.53 PM.png", "1010", "721", "#843c9c", "" ] } ] } [/block] Or signing up if we don't have a Yo account [block:image] { "images": [ { "image": [ "https://files.readme.io/YiSTKju7RjKPQbdgoh1i_Screen%20Shot%202015-07-29%20at%203.45.04%20PM.png", "Screen Shot 2015-07-29 at 3.45.04 PM.png", "1010", "744", "#8c44a4", "" ] } ] } [/block] [block:image] { "images": [ { "image": [ "https://files.readme.io/d8s3BsMRVOzh7fGYpYjX_Screen%20Shot%202015-07-29%20at%203.45.34%20PM.png", "Screen Shot 2015-07-29 at 3.45.34 PM.png", "1010", "744", "#4a627b", "" ] } ] } [/block] [block:image] { "images": [ { "image": [ "https://files.readme.io/nHtKu76SR9yMztLcvEWB_Screen%20Shot%202015-07-29%20at%203.46.46%20PM.png", "Screen Shot 2015-07-29 at 3.46.46 PM.png", "1010", "744", "#4b6179", "" ] } ] } [/block] [block:image] { "images": [ { "image": [ "https://files.readme.io/ewfVnYo9QsO6SMb6qNnM_Screen%20Shot%202015-07-29%20at%203.46.53%20PM.png", "Screen Shot 2015-07-29 at 3.46.53 PM.png", "1010", "744", "#54687f", "" ] } ] } [/block] [block:image] { "images": [ { "image": [ "https://files.readme.io/jCly135lSnWXP6Rq2avn_Screen%20Shot%202015-07-29%20at%203.47.31%20PM.png", "Screen Shot 2015-07-29 at 3.47.31 PM.png", "1010", "744", "#496078", "" ] } ] } [/block]