Skip to main content
POST
/
commissions
Go
package main

import(
	"context"
	pearset "github.com/pearset/pearset-go"
	"log"
)

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

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

    res, err := s.Commissions.Create(ctx, nil)
    if err != nil {
        log.Fatal(err)
    }
    if res != nil {
        // handle response
    }
}
{
  "success": true,
  "message": "<string>"
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Body

application/json
type
enum<string>
required
Available options:
custom
partnerId
string
required

The ID of the partner to create the commission for.

amount
number
required

The commission amount in cents.

date
string | null

If not provided, the current date will be used.

description
string | null

The description of the commission.

Maximum string length: 190

Response

The request was accepted and commission creation was queued.

success
boolean
required
message
string
required