PATCH
/
v1
/
organizations
/
{id}
package main

import(
	"context"
	"os"
	polargo "github.com/polarsource/polar-go"
	"github.com/polarsource/polar-go/models/components"
	"log"
)

func main() {
    ctx := context.Background()
    
    s := polargo.New(
        polargo.WithSecurity(os.Getenv("POLAR_ACCESS_TOKEN")),
    )

    res, err := s.Organizations.Update(ctx, "<value>", components.OrganizationUpdate{})
    if err != nil {
        log.Fatal(err)
    }
    if res.Organization != nil {
        // handle response
    }
}
{
  "created_at": "2023-11-07T05:31:56Z",
  "modified_at": "2023-11-07T05:31:56Z",
  "id": "<string>",
  "name": "<string>",
  "slug": "<string>",
  "avatar_url": "<string>",
  "bio": "<string>",
  "company": "<string>",
  "blog": "<string>",
  "location": "<string>",
  "email": "<string>",
  "twitter_username": "<string>",
  "pledge_minimum_amount": 123,
  "pledge_badge_show_amount": true,
  "default_upfront_split_to_contributors": 123,
  "profile_settings": {
    "enabled": true,
    "description": "<string>",
    "featured_projects": [
      "<string>"
    ],
    "featured_organizations": [
      "<string>"
    ],
    "links": [
      "<string>"
    ],
    "subscribe": {
      "promote": true,
      "show_count": true,
      "count_free": true
    },
    "accent_color": "<string>"
  },
  "feature_settings": {
    "issue_funding_enabled": false
  },
  "subscription_settings": {
    "allow_multiple_subscriptions": true,
    "allow_customer_updates": true,
    "proration_behavior": "invoice"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

The organization ID.

Body

application/json
name
string | null
Minimum length: 3
avatar_url
string | null
Required string length: 1 - 2083
default_upfront_split_to_contributors
integer | null
Required range: 0 < x < 100
pledge_badge_show_amount
boolean
default:
false
billing_email
string | null
default_badge_custom_content
string | null
pledge_minimum_amount
integer
default:
2000
total_monthly_spending_limit
integer | null
per_user_monthly_spending_limit
integer | null
profile_settings
object | null
feature_settings
object | null
subscription_settings
object | null

Response

200
application/json
Organization updated.
created_at
string
required

Creation timestamp of the object.

modified_at
string | null
required

Last modification timestamp of the object.

id
string
required

The organization ID.

name
string
required
slug
string
required
avatar_url
string | null
required
bio
string | null
required
company
string | null
required
blog
string | null
required
location
string | null
required
email
string | null
required
twitter_username
string | null
required
pledge_minimum_amount
integer
required
pledge_badge_show_amount
boolean
required
default_upfront_split_to_contributors
integer | null
required
profile_settings
object | null
required

Settings for the organization profile

feature_settings
object | null
required

Settings for the organization features

subscription_settings
object
required

Settings related to subscriptions management