FORMAT: 1A
HOST: http://192.168.0.53:5555

# Group Vectorapi
Group of all vectorapi-related resources.

## Artist

Artist is the one who wants to release his album. So each release is assigned to an artist. A vendor can have multiple artists. Artist can be a single or a group of persons.
ArtistInfo resource deals with artist's basic info, its social connections, etc. It consists of all relevant functions of an artist such as add, edit, delete.

## Post [/vectorapi/artist/post{?data,access_token}]

### Post [POST]

+ Parameters

    + data (varchar, `{"vendor_id":7123,"name":"Test Artist -4","orchard_country":8}`)
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)
    + Body
{
  "artist_id": 645785
}

## Put [/vectorapi/artist/put{?data,access_token}]

### Put [POST]

+ Parameters
    
    + data (varchar, `{"artist_id":645785,"vendor_id":7123,"name":"Test Artist -3","orchard_country":8}`)
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "artist_id": 645785
}

## Get [/vectorapi/artist/get{?artist_id,access_token}]

### Get [GET]

+ Parameters

    + artist_id (number, `645785`) ... Primary key of artist table.
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "artist": {
    "artist_id": 645785,
    "url": null,
    "artist_email": null,
    "when_entered": {
      "date": "2014-03-10 06:53:04",
      "timezone_type": 3,
      "timezone": "America/New_York"
    },
    "entered_by": "7123",
    "description": null,
    "name": "Test Artist -3",
    "vendor_id": 7123,
    "last_updated": {
      "date": "2014-03-10 07:01:58",
      "timezone_type": 3,
      "timezone": "America/New_York"
    },
    "join_artist_id": null,
    "myspace_url": null,
    "myspace_id": null,
    "address_city": null,
    "address_state": null,
    "address_other_state": null,
    "orchard_country": 8,
    "active": "-",
    "tms_id": null,
    "address_zip": null,
    "youtube_mytourdate_url": null,
    "twitter_mytourdate_url": null,
    "primary_photo_id": null,
    "artist_type": "artist",
    "AdditionalArtistInfo": [],
    "ArtistUrl": [],
    "ArtistInfoProfileCompletion": [
      {
        "id": 85447,
        "completed_percentage": 0,
        "last_updated": {
          "date": "2014-03-10 07:01:58",
          "timezone_type": 3,
          "timezone": "America/New_York"
        },
        "total_completed": 0,
        "ArtistInfoProfileSections": {
          "section_id": 1,
          "section": "info",
          "weight": true
        }
      }
    ]
  }
}

## Index [/vectorapi/artist/index{?labelIds,limit,access_token}]

### Index [GET]

+ Parameters

    + labelIds (required, number, `7123`)
    + limit (required, number, `5`)
    + access_token (optional, varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "envelope": {
    "header": {
      "apiVersion": "1.0",
      "baseUrl": "vapi.alpha.devorch.com",
      "httpStatusCode": 200
    },
    "request": "artist/index?params=vectorapi&artist&index&7123&5&<some_token>&json",
    "response": {
      "artistsInfo": [
        {
          "artistId": "233414",
          "artistName": "00 Delete this brand",
          "labelId": "7123"
        },
        {
          "artistId": "233415",
          "artistName": "00 Delete this brand 2",
          "labelId": "7123"
        },
        {
          "artistId": "233598",
          "artistName": "00 Delete this brand 3",
          "labelId": "7123"
        },
        {
          "artistId": "171733",
          "artistName": "00000 test",
          "labelId": "7123"
        },
        {
          "artistId": "603918",
          "artistName": "000000 DuPre Test",
          "labelId": "7123"
        }
      ],
      "totalRecords": "959"
    }
  }
}

## Delete [/vectorapi/artist{?id,access_token}]

### Delete [DELETE]

+ Parameters

    + id (number, `582592`) ... Primary key of artist table.
    + access_token (varchar, `some token`)

+ Request JSON Message
    
    + Headers

            Accept: application/json

+ Response 200 (application/json)

    + Body
{
  "response": "success"
}
