Writing
Make Board
POST
/boards
package main
import ( "fmt" "strings" "net/http" "io")
func main() {
url := "http://localhost:3000/api/v1/boards"
payload := strings.NewReader("{ \"name\": \"example\" }")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>") req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := io.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}const url = 'http://localhost:3000/api/v1/boards';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:3000/api/v1/boards \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example" }'A new empty board owned by the key’s person. A retry after a lost answer may make a second board.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
NewBoard
object
name
required
Name
string
Example generated
{ "name": "example"}Responses
Section titled “Responses”Successful Response
Media typeapplication/json
Board
object
id
required
Id
string
name
required
Name
string
role
required
Role
string
updated_at
required
Updated At
string
public
required
Public
boolean
shared_with_everyone
required
Shared With Everyone
boolean
url
required
Url
string
Example
{ "role": "owner"}No key, or a key that stopped working
Media typeapplication/json
Error
Every error of v1; clients must ignore codes they do not know.
object
error
required
ErrorDetail
object
code
required
Code
string
message
required
Message
string
Example generated
{ "error": { "code": "example", "message": "example" }}The key may not do this, or keys are switched off
Media typeapplication/json
Error
Every error of v1; clients must ignore codes they do not know.
object
error
required
ErrorDetail
object
code
required
Code
string
message
required
Message
string
Example generated
{ "error": { "code": "example", "message": "example" }}Not found, or not among what the key reaches
Media typeapplication/json
Error
Every error of v1; clients must ignore codes they do not know.
object
error
required
ErrorDetail
object
code
required
Code
string
message
required
Message
string
Example generated
{ "error": { "code": "example", "message": "example" }}The request does not match the schema
Media typeapplication/json
Error
Every error of v1; clients must ignore codes they do not know.
object
error
required
ErrorDetail
object
code
required
Code
string
message
required
Message
string
Example generated
{ "error": { "code": "example", "message": "example" }}Over a budget; see Retry-After
Media typeapplication/json
Error
Every error of v1; clients must ignore codes they do not know.
object
error
required
ErrorDetail
object
code
required
Code
string
message
required
Message
string
Example generated
{ "error": { "code": "example", "message": "example" }}