Closed jwulf closed 8 years ago
And add "Don't have an account? Create one here"
lnewson: {"name": "
Below should be correct and all you need to add an assigned writer. You'll need to replace <USERNAME>, <FIRSTNAME>, <SURNAME> and <EMAIL>
URL:
POST <SERVER_URL>/1/tag/create/json
Formatted JSON Request:
{
"name":"<USERNAME>",
"configuredParameters": ["categories", "properties", "name"],
"categories":
{
"items":
[
{
"item": {"id": "12"},
"state": "1"
}
]
},
"properties":
{
"items":
[
{
"item": {"id": "1", "value": "<FIRSTNAME>", "configuredParameters": ["value"]},
"state": "1"
},
{
"item": {"id": "2", "value": "<SURNAME>", "configuredParameters": ["value"]},
"state": "1"
},
{
"item": {"id": "3", "value": "<EMAIL>", "configuredParameters": ["value"]},
"state": "1"
}
]
}
}
Unformatted JSON Request:
{"name":"<USERNAME>", "configuredParameters": ["categories", "properties", "name"], "categories": {"items": [{"item": {"id": "12"}, "state": "1"}]}, "properties": {"items": [{"item": {"id": "1", "value": "<FIRSTNAME>", "configuredParameters": ["value"]}, "state": "1"}, {"item": {"id": "2", "value": "<SURNAME>", "configuredParameters": ["value"]}, "state": "1"}, {"item": {"id": "3", "value": "<EMAIL>", "configuredParameters": ["value"]}, "state": "1"}]}}
https://github.com/jwulf/press-star/commit/f3ed30311f343ac8b31508dfaab16196b2190499
Done. Just have to create the assigned writer tag now, and it's golden.
Here's what a succcessful assigned writer request looked like in PG:
{"revisions":null, "name":"jbourne", "description":null, "categories":{"items":[{"item":{"relationshipId":null, "relationshipSort":0, "revisions":null, "name":null, "description":null, "mutuallyExclusive":false, "sort":null, "tags":null, "selfLink":null, "editLink":null, "deleteLink":null, "addLink":null, "id":12, "revision":null, "configuredParameters":["tagCategorySort"], "expand":null, "logDetails":null}, "state":1}], "size":null, "expand":null, "startExpandIndex":null, "endExpandIndex":null}, "parentTags":null, "childTags":null, "projects":{"items":[], "size":null, "expand":null, "startExpandIndex":null, "endExpandIndex":null}, "properties":{"items":[], "size":null, "expand":null, "startExpandIndex":null, "endExpandIndex":null}, "selfLink":null, "editLink":null, "deleteLink":null, "addLink":null, "id":-1, "revision":null, "configuredParameters":["description","name","properties","categories","projects"], "expand":null, "logDetails":null}
Sorry I used the wrong ID on the Assigned Writer category (it should have been 12 not 4). Also your request doesn't set the "First Name", "Last Name" or "Email" extended properties, so it's not right either.
Closing.
http://twitter.github.io/bootstrap/javascript.html#modals