{"action":"created","issue":{"url":"https://api.github.com/repos/Mashape/kong/issues/682","labels_url":"https://api.github.com/repos/Mashape/kong/issues/682/labels{/name}","comments_url":"https://api.github.com/repos/Mashape/kong/issues/682/comments","events_url":"https://api.github.com/repos/Mashape/kong/issues/682/events","html_url":"https://github.com/Mashape/kong/issues/682","id":115185168,"number":682,"title":"Admin API should have a \"provisioning\" endpoint","user":{"login":"ahmadnassri","id":183195,"avatar_url":"https://avatars.githubusercontent.com/u/183195?v=3","gravatar_id":"","url":"https://api.github.com/users/ahmadnassri","html_url":"https://github.com/ahmadnassri","followers_url":"https://api.github.com/users/ahmadnassri/followers","following_url":"https://api.github.com/users/ahmadnassri/following{/other_user}","gists_url":"https://api.github.com/users/ahmadnassri/gists{/gist_id}","starred_url":"https://api.github.com/users/ahmadnassri/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahmadnassri/subscriptions","organizations_url":"https://api.github.com/users/ahmadnassri/orgs","repos_url":"https://api.github.com/users/ahmadnassri/repos","events_url":"https://api.github.com/users/ahmadnassri/events{/privacy}","received_events_url":"https://api.github.com/users/ahmadnassri/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-11-05T00:55:08Z","updated_at":"2015-11-05T18:30:48Z","closed_at":null,"body":"provisioning endpoint does two things:\n\n- create a consumer object\n- create credentials for the generated consumer in association to what authentication method(s) are enabled on an API\n\ne.g.\n\n```bash\ncurl -X POST localhost:8001/apis/{id}/provision/ --data \"username=foo\" --data \"secret=abc\"\n```\n\nWhich returns something like:\n\n```json\n{\n  \"authentication\": \"basic\", \n  \"credential\": {\n    \"id\": \"id123\", \n    \"keys\": { \n      \"username\": \"foo\", \n      \"password\": \"abc\" \n    }\n  }\n}\n```\n"},"comment":{"url":"https://api.github.com/repos/Mashape/kong/issues/comments/154146052","html_url":"https://github.com/Mashape/kong/issues/682#issuecomment-154146052","issue_url":"https://api.github.com/repos/Mashape/kong/issues/682","id":154146052,"user":{"login":"ahmadnassri","id":183195,"avatar_url":"https://avatars.githubusercontent.com/u/183195?v=3","gravatar_id":"","url":"https://api.github.com/users/ahmadnassri","html_url":"https://github.com/ahmadnassri","followers_url":"https://api.github.com/users/ahmadnassri/followers","following_url":"https://api.github.com/users/ahmadnassri/following{/other_user}","gists_url":"https://api.github.com/users/ahmadnassri/gists{/gist_id}","starred_url":"https://api.github.com/users/ahmadnassri/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahmadnassri/subscriptions","organizations_url":"https://api.github.com/users/ahmadnassri/orgs","repos_url":"https://api.github.com/users/ahmadnassri/repos","events_url":"https://api.github.com/users/ahmadnassri/events{/privacy}","received_events_url":"https://api.github.com/users/ahmadnassri/received_events","type":"User","site_admin":false},"created_at":"2015-11-05T18:30:48Z","updated_at":"2015-11-05T18:30:48Z","body":"like a root endpoint? \n\n```\nPOST /provision\n\n{\n  \"api_id\": \"abc\",\n  \"consumers\": [ ... ]\n}\n```"}}