FORMAT: 1A
HOST: https://orgmanager.miguelpiedrafita.com/api

# Orgmanager API

The Orgmanager API allows you to integrate Orgmanager with other applications and projects.

## Questions Collection [/questions]

### List All Questions [GET]

+ Response 200 (application/json)

        [
            {
                "question": "Favourite programming language?",
                "published_at": "2015-08-05T08:40:51.620Z",
                "choices": [
                    {
                        "choice": "Swift",
                        "votes": 2048
                    }, {
                        "choice": "Python",
                        "votes": 1024
                    }, {
                        "choice": "Objective-C",
                        "votes": 512
                    }, {
                        "choice": "Ruby",
                        "votes": 256
                    }
                ]
            }
        ]

### Create a New Question [POST]

You may create your own question using this action. It takes a JSON
object containing a question and a collection of answers in the
form of choices.

+ Request (application/json)

        {
            "question": "Favourite programming language?",
            "choices": [
                "Swift",
                "Python",
                "Objective-C",
                "Ruby"
            ]
        }

+ Response 201 (application/json)

    + Headers

            Location: /questions/2

    + Body

            {
                "question": "Favourite programming language?",
                "published_at": "2015-08-05T08:40:51.620Z",
                "choices": [
                    {
                        "choice": "Swift",
                        "votes": 0
                    }, {
                        "choice": "Python",
                        "votes": 0
                    }, {
                        "choice": "Objective-C",
                        "votes": 0
                    }, {
                        "choice": "Ruby",
                        "votes": 0
                    }
                ]
            }

FORMAT: 1A
HOST: https://orgmanager.miguelpiedrafita.com/api

# Orgmanager API

The Orgmanager API allows you to integrate Orgmanager with other applications and projects.

## User Data [/user]

### Get user info [GET]

+ Response 200 (application/json)

        {
            "id":1,
            "name":"Miguel Piedrafita",
            "email":"soy@miguelpiedrafita.com",
            "github_username":"m1guelpf",
            "created_at":"2017-01-25 18:44:32",
            "updated_at":"2017-02-16 19:40:50"
        }

## User Organizations [/user/orgs]

### Get user organizations [GET]

+ Response 200 (application/json)

        {
            "id":1,
            "name":"Test Organization",
            "url":"https:\/\/api.github.com\/orgs\/test-org",
            "description":null,
            "avatar":"https:\/\/miguelpiedrafita.com\/logo.png",
            "invitecount":100
        }
