POST ONE READER WITH DOCUMENT-ID
PUT {{base_doc_url}}{{doc_api}}/{{namespace}}/collections/{{collection}}/{{readerdocid}}
Request Body
{"reader"=>{"name"=>"John Smith", "user_id"=>"12346", "birthdate"=>"11-01-1992", "email"=>{"primary"=>"jsmith@gmail.com", "secondary"=>"john.smith@aol.com"}, "address"=>{"primary"=>{"street"=>"200 Z St", "city"=>"Evertown", "state"=>"MA", "zip-code"=>55555}, "secondary"=>{"street"=>"850 2nd St", "city"=>"Evertown", "state"=>"MA", "zip-code"=>55556}}, "reviews"=>[{"book_title"=>"Moby Dick", "rating"=>3, "review-date"=>"02-02-2002", "comment"=>"It was okay."}, {"book_title"=>"Pride and Prejudice", "rating"=>5, "review-date"=>"03-02-2002", "comment"=>"It was a wonderful book! I loved reading it."}]}}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
X-Cassandra-Token | string | (Required) The token returned from the authorization endpoint. Use this token in each request to the database. | |
Content-Type | string |
RESPONSES
status: Created
{"name":"killrvideo"}