anchor.diff:  + Response 201
   
       [Subject][]
  -                
  +
  +# Group Projects
  +Resources related to _Panoptes Projects_.
  +
  +## Project [/projects/{id}]
  +A single project object. A Project is a collection of subjects,
  +workflows, and supplementary text that describe the task a volunteer
  +is being asked to perform.
  +
  +It has the following attributes
  +
  +- id
  +- created_at
  +- updated_at
  +- name
  +- display_name
  +- content
  +- user_count
  +- classification_count
  +- activated_state
  +- primary_language
  +- visible_to
  +
  +*id*, *created_at*, *updated_at*, *user_count*, and
  + *classification_count* are set by the API.
  +
  ++ Model (application/vnd.api+json)
  +
  +    + Body
  +            
  +            {
  +                "links": {
  +                    "projects.subjects": {
  +                        "href": "/subjects{?project_id=projects.id}
  +                        "type": "subject"
  +                    },
  +                    "projects.classifications": {
  +                        "href": "/classifications{?project_id=projects.id}",
  +                        "type": "classification"
  +                    },
  +                    "projects.workflows": {
  +                        "href": "/workflows/{projects.workflows}",
  +                        "type": "workflow"
  +                    },
  +                    "projects.subject_sets": {
  +                        "href": "/subject_sets/{projects.subject_sets}",
  +                        "type": "subject_Sets"
  +                    },
  +                },
  +                "projects": {
  +                    "id": "1",
  +                    "created_at": "2014-03-24T10:42:21Z",
  +                    "updated_at": "2014-03-24T10:42:21Z",
  +                    "name": "galaxy_zoo",
  +                    "display_name": "Galaxy Zoo",
  +                    "primary_language": "en",
  +                    "user_count": "10000",
  +                    "classification_count": "1000000",
  +                    "activated_state": 0,
  +                    "visible_to": [],
  +                    "content": {
  +                        "title": "Galaxy Zoo",
  +                        "description": "A Project ...",
  +                        "pages": {},
  +                        "language": "en"
  +                    },
  +                    links: {
  +                        "workflows": ["1", "2"],
  +                        "subject_sets": ["10", "13"],
  +                        "owner": {
  +                            id: "2",
  +                            href: "/users/2",
  +                            type: "user"
  +                        }
  +                    }
  +                }
  +            }
  +
  +### Retrieve a single Project [GET]
  +
  ++ Response 200
  +
  +    [Project][]
  +
  +### Edit a single Project [PUT]
  +A User must be the owner of a project or have update
  +permissions to edit. Workflow and Subject links may be edited. Removing a
  +subject set or workflow causes it be destroyed. Added a workflow or
  +subject set causes the original to be copied and a new id to be
  +returned. 
  +
  ++ Request (application/vnd.api+json)
  +
  +        {
  +            "projects": {
  +                "display_name": "Galaxy Zooooooooo!"
  +                "links": {
  +                    "workflows": ["1"]
  +                    "subject_sets": ["10"]
  +                }
  +            }
  +        }
  +
  ++ Response 200
  +
  +    [Project][]
  +
  +### Destroy a single Project [DELETE]
  +A user may destroy a project they are the owner of or they have
  +destroy permissions for.
  +
  ++ Response 204
  +
  +## Project Create Links [/project/{id}/links/{link_type}]
  +An alternative way to edit a project's subject set and workflow
  +links.
  +
  +### Add a Link [POST]
  +The body key must match the link_type parameter. Workflow and Subjects
  +added in this way will be copied and their id will be returned as part
  +of the complete Project representation response.
  +
  ++ Parameters
  +  + id (required, integer) ... the id of the project to modify
  +  + link_type (required, string) ... the name of the link to edit. May
  +    only be workflow or subject_set
  +
  ++ Request (application/vnd.api+json)
  +
  +        {
  +            "subject_sets": ["1", "2"]
  +        }
  +
  ++ Response 200
  +
  +    [Project][]
  +
  +## Project Destroy Links [/project/{id}/links/{link_type}/{link_ids]
  +An alternative way to destroy project links.
  +
  +### Destroy a Link [DELETE]
  +Will destroy the comma seperated list of link ids for the given link
  +type. For Projects, only workflow and subject_set links can be
  +destroyed in this manner. The linked object will be destroyed with
  +this action.
  +
  ++ Parameters
  +  + id (required, integer) ... the id of the project to modify
  +  + link_type (required, string) .... the name of the link to
  +    edit. May only be subject_set or workflow
  +  + link_ids (required, string) ... comma seperated list of ids to
  +    modify
  +
  ++ Response 204
  +
  +## Project Collection [/projects{?page,per_page,sort,owner}]
  +A collection of _Panotpes Project_ resources.
  +
  +All collections add a *meta* attribute that is a hash containing
  +paging information.
  +
  +- meta
  +
  +Projects are returned as an array under the _projects_ key.
  +
  ++ Model (application/vnd.api+json)
  +
  +    A JSON API formatted representation of a collection of Projects.
  +
  +    + Body
  +    
  +            {
  +                "links": {
  +                    "projects.subjects": {
  +                        "href": "/subjects{?project_id=projects.id}
  +                        "type": "subject"
  +                    },
  +                    "projects.classifications": {
  +                        "href": "/classifications{?project_id=projects.id}",
  +                        "type": "classification"
  +                    },
  +                    "projects.workflows": {
  +                        "href": "/workflows/{projects.workflows}",
  +                        "type": "workflow"
  +                    },
  +                    "projects.subject_sets": {
  +                        "href": "/subject_sets/{projects.subject_sets}",
  +                        "type": "subject_Sets"
  +                    },
  +                },
  +                "meta": {
  +                   "projects": {
  +                        "page": 1,
  +                        "page_size": 2,
  +                        "count": 28,
  +                        "include": [],
  +                        "page_count": 14,
  +                        "previous_page": 14,
  +                        "next_page": 2,
  +                        "first_href": "/projects?page_size=2",
  +                        "previous_href": "/projects?page=14page_size=2",
  +                        "next_href": "/projects?page=2&page_size=2",
  +                        "last_href": "/projects?page=14&page_size=2"
  +                    }
  +                },
  +                "projects": [{
  +                    "id": "1",
  +                    "created_at": "2014-03-24T10:42:21Z",
  +                    "updated_at": "2014-03-24T10:42:21Z",
  +                    "name": "galaxy_zoo",
  +                    "display_name": "Galaxy Zoo",
  +                    "primary_language": "en",
  +                    "user_count": "10000",
  +                    "classification_count": "1000000",
  +                    "activated_state": 0,
  +                    "visible_to": [],
  +                    "content": {
  +                        "title": "Galaxy Zoo",
  +                        "description": "A Project ...",
  +                        "pages": {},
  +                        "language": "en"
  +                    },
  +                    links: {
  +                        "workflows": ["1", "2"],
  +                        "subject_sets": ["10", "13"],
  +                        "owner": {
  +                            id: "2",
  +                            href: "/users/2",
  +                            type: "user"
  +                        }
  +                    }
  +                },{
  +                    "id": "2",
  +                    "created_at": "2014-04-24T10:42:21Z",
  +                    "updated_at": "2014-04-24T10:42:21Z",
  +                    "name": "planet_hunters",
  +                    "display_name": "Planet Hunters",
  +                    "primary_language": "zh-tw",
  +                    "user_count": "100000",
  +                    "classification_count": "122340000000",
  +                    "activated_state": 0,
  +                    "visible_to": [],
  +                    "content": {
  +                        "title": "Planet Hunters",
  +                        "description": "A Project ...",
  +                        "pages": {},
  +                        "language": "zw-tw"
  +                    },
  +                    links: {
  +                        "workflows": ["10", "21"],
  +                        "subject_sets": ["11", "12"],
  +                        "owner": {
  +                            id: "2",
  +                            href: "/users/2",
  +                            type: "user"
  +                        }
  +                    }
  +                }]
  +            }
  +            
  +### List All Projects [GET]
  ++ Parameters
  +  + page (optional, integer) ... the index of the page to retrieve
  +    default is 1
  +  + per_page (optional, integer) ... number of items to include on a
  +    page default is 20
  +  + sort (optional, string) ... field to sort by
  +  + owner (optional, string) ... string owner name of either a user or
  +    a user group to filter by.
  +
  ++ Response 200
  +
  +    [Project Collection][]
  +
  +
  +### Create a Project [POST]
  +Requires at least a name, description, and primary language. Workflows
  +and Subject sets added as links will be copied and their new ids
  +returned.
  +
  ++ Request (application/vnd.api+json)
  +
  +        {
  +            "projects": {
  +                "name": "galaxy_zoo"
  +                "description": "A doubleplus good project",
  +                "language": "en-us",
  +                "links": {
  +                    "workflows": ["1", "2"]
  +                    "owner": {
  +                        "id": 10,
  +                        "type": "user_group"
  +                    }
  +                }
  +            }
  +        }
  +
  ++ Response 201
  +
  +    [Project][]
                   
                   
               
  +
  
positive.code:                     "subjects.project": {
                          "href": "/projects/subjects.project",
                          "type": "project"
                      },
                  },
                  "meta": {
                      "subjects": {
  
negative.code:                     "subjects.project": {
                          "href": "/projects/subjects.project",
                          "type": "project"
                      }
                  },
                  "subjects": {
                      "id": "1",
  