POST
/
tags
package main

import(
	"context"
	dubgo "github.com/dubinc/dub-go"
	"log"
)

func main() {
    ctx := context.Background()

    s := dubgo.New(
        dubgo.WithSecurity("DUB_API_KEY"),
    )

    res, err := s.Tags.Create(ctx, nil)
    if err != nil {
        log.Fatal(err)
    }
    if res != nil {
        // handle response
    }
}
{
  "id": "<string>",
  "name": "<string>",
  "color": "red"
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Body

application/json

Response

201
application/json

The created tag

The response is of type object.