1. Packages
  2. Packages
  3. Konnect Provider
  4. API Docs
  5. OrganizationPersonalAccessTokenSettings
Viewing docs for konnect 3.21.0
published on Tuesday, Aug 4, 2026 by kong
Viewing docs for konnect 3.21.0
published on Tuesday, Aug 4, 2026 by kong

    OrganizationPersonalAccessTokenSettings Resource

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as konnect from "@pulumi/konnect";
    
    const myOrganizationpersonalaccesstokensettings = new konnect.OrganizationPersonalAccessTokenSettings("my_organizationpersonalaccesstokensettings", {
        maxExpirationPeriodDays: 170,
        organizationId: "5f9fd312-a987-4628-b4c5-bb4f4fddd5f7",
        patsEnabled: true,
    });
    
    import pulumi
    import pulumi_konnect as konnect
    
    my_organizationpersonalaccesstokensettings = konnect.OrganizationPersonalAccessTokenSettings("my_organizationpersonalaccesstokensettings",
        max_expiration_period_days=170,
        organization_id="5f9fd312-a987-4628-b4c5-bb4f4fddd5f7",
        pats_enabled=True)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/konnect/v3/konnect"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := konnect.NewOrganizationPersonalAccessTokenSettings(ctx, "my_organizationpersonalaccesstokensettings", &konnect.OrganizationPersonalAccessTokenSettingsArgs{
    			MaxExpirationPeriodDays: pulumi.Float64(170),
    			OrganizationId:          pulumi.String("5f9fd312-a987-4628-b4c5-bb4f4fddd5f7"),
    			PatsEnabled:             pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Konnect = Pulumi.Konnect;
    
    return await Deployment.RunAsync(() => 
    {
        var myOrganizationpersonalaccesstokensettings = new Konnect.OrganizationPersonalAccessTokenSettings("my_organizationpersonalaccesstokensettings", new()
        {
            MaxExpirationPeriodDays = 170,
            OrganizationId = "5f9fd312-a987-4628-b4c5-bb4f4fddd5f7",
            PatsEnabled = true,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.konnect.OrganizationPersonalAccessTokenSettings;
    import com.pulumi.konnect.OrganizationPersonalAccessTokenSettingsArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var myOrganizationpersonalaccesstokensettings = new OrganizationPersonalAccessTokenSettings("myOrganizationpersonalaccesstokensettings", OrganizationPersonalAccessTokenSettingsArgs.builder()
                .maxExpirationPeriodDays(170.0)
                .organizationId("5f9fd312-a987-4628-b4c5-bb4f4fddd5f7")
                .patsEnabled(true)
                .build());
    
        }
    }
    
    resources:
      myOrganizationpersonalaccesstokensettings:
        type: konnect:OrganizationPersonalAccessTokenSettings
        name: my_organizationpersonalaccesstokensettings
        properties:
          maxExpirationPeriodDays: 170
          organizationId: 5f9fd312-a987-4628-b4c5-bb4f4fddd5f7
          patsEnabled: true
    
    Example coming soon!
    

    Create OrganizationPersonalAccessTokenSettings Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new OrganizationPersonalAccessTokenSettings(name: string, args: OrganizationPersonalAccessTokenSettingsArgs, opts?: CustomResourceOptions);
    @overload
    def OrganizationPersonalAccessTokenSettings(resource_name: str,
                                                args: OrganizationPersonalAccessTokenSettingsArgs,
                                                opts: Optional[ResourceOptions] = None)
    
    @overload
    def OrganizationPersonalAccessTokenSettings(resource_name: str,
                                                opts: Optional[ResourceOptions] = None,
                                                organization_id: Optional[str] = None,
                                                max_expiration_period_days: Optional[float] = None,
                                                pats_enabled: Optional[bool] = None)
    func NewOrganizationPersonalAccessTokenSettings(ctx *Context, name string, args OrganizationPersonalAccessTokenSettingsArgs, opts ...ResourceOption) (*OrganizationPersonalAccessTokenSettings, error)
    public OrganizationPersonalAccessTokenSettings(string name, OrganizationPersonalAccessTokenSettingsArgs args, CustomResourceOptions? opts = null)
    public OrganizationPersonalAccessTokenSettings(String name, OrganizationPersonalAccessTokenSettingsArgs args)
    public OrganizationPersonalAccessTokenSettings(String name, OrganizationPersonalAccessTokenSettingsArgs args, CustomResourceOptions options)
    
    type: konnect:OrganizationPersonalAccessTokenSettings
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "konnect_organization_personal_access_token_settings" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args OrganizationPersonalAccessTokenSettingsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args OrganizationPersonalAccessTokenSettingsArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args OrganizationPersonalAccessTokenSettingsArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args OrganizationPersonalAccessTokenSettingsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args OrganizationPersonalAccessTokenSettingsArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var organizationPersonalAccessTokenSettingsResource = new Konnect.OrganizationPersonalAccessTokenSettings("organizationPersonalAccessTokenSettingsResource", new()
    {
        OrganizationId = "string",
        MaxExpirationPeriodDays = 0,
        PatsEnabled = false,
    });
    
    example, err := konnect.NewOrganizationPersonalAccessTokenSettings(ctx, "organizationPersonalAccessTokenSettingsResource", &konnect.OrganizationPersonalAccessTokenSettingsArgs{
    	OrganizationId:          pulumi.String("string"),
    	MaxExpirationPeriodDays: pulumi.Float64(0),
    	PatsEnabled:             pulumi.Bool(false),
    })
    
    resource "konnect_organization_personal_access_token_settings" "organizationPersonalAccessTokenSettingsResource" {
      lifecycle {
        create_before_destroy = true
      }
      organization_id            = "string"
      max_expiration_period_days = 0
      pats_enabled               = false
    }
    
    var organizationPersonalAccessTokenSettingsResource = new OrganizationPersonalAccessTokenSettings("organizationPersonalAccessTokenSettingsResource", OrganizationPersonalAccessTokenSettingsArgs.builder()
        .organizationId("string")
        .maxExpirationPeriodDays(0.0)
        .patsEnabled(false)
        .build());
    
    organization_personal_access_token_settings_resource = konnect.OrganizationPersonalAccessTokenSettings("organizationPersonalAccessTokenSettingsResource",
        organization_id="string",
        max_expiration_period_days=float(0),
        pats_enabled=False)
    
    const organizationPersonalAccessTokenSettingsResource = new konnect.OrganizationPersonalAccessTokenSettings("organizationPersonalAccessTokenSettingsResource", {
        organizationId: "string",
        maxExpirationPeriodDays: 0,
        patsEnabled: false,
    });
    
    type: konnect:OrganizationPersonalAccessTokenSettings
    properties:
        maxExpirationPeriodDays: 0
        organizationId: string
        patsEnabled: false
    

    OrganizationPersonalAccessTokenSettings Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The OrganizationPersonalAccessTokenSettings resource accepts the following input properties:

    OrganizationId string
    A UUID representing an organization.
    MaxExpirationPeriodDays double
    PatsEnabled bool
    OrganizationId string
    A UUID representing an organization.
    MaxExpirationPeriodDays float64
    PatsEnabled bool
    organization_id string
    A UUID representing an organization.
    max_expiration_period_days number
    pats_enabled bool
    organizationId String
    A UUID representing an organization.
    maxExpirationPeriodDays Double
    patsEnabled Boolean
    organizationId string
    A UUID representing an organization.
    maxExpirationPeriodDays number
    patsEnabled boolean
    organization_id str
    A UUID representing an organization.
    max_expiration_period_days float
    pats_enabled bool
    organizationId String
    A UUID representing an organization.
    maxExpirationPeriodDays Number
    patsEnabled Boolean

    Outputs

    All input properties are implicitly available as output properties. Additionally, the OrganizationPersonalAccessTokenSettings resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing OrganizationPersonalAccessTokenSettings Resource

    Get an existing OrganizationPersonalAccessTokenSettings resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: OrganizationPersonalAccessTokenSettingsState, opts?: CustomResourceOptions): OrganizationPersonalAccessTokenSettings
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            max_expiration_period_days: Optional[float] = None,
            organization_id: Optional[str] = None,
            pats_enabled: Optional[bool] = None) -> OrganizationPersonalAccessTokenSettings
    func GetOrganizationPersonalAccessTokenSettings(ctx *Context, name string, id IDInput, state *OrganizationPersonalAccessTokenSettingsState, opts ...ResourceOption) (*OrganizationPersonalAccessTokenSettings, error)
    public static OrganizationPersonalAccessTokenSettings Get(string name, Input<string> id, OrganizationPersonalAccessTokenSettingsState? state, CustomResourceOptions? opts = null)
    public static OrganizationPersonalAccessTokenSettings get(String name, Output<String> id, OrganizationPersonalAccessTokenSettingsState state, CustomResourceOptions options)
    resources:  _:    type: konnect:OrganizationPersonalAccessTokenSettings    get:      id: ${id}
    import {
      to = konnect_organization_personal_access_token_settings.example
      id = "${id}"
    }
    
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    MaxExpirationPeriodDays double
    OrganizationId string
    A UUID representing an organization.
    PatsEnabled bool
    MaxExpirationPeriodDays float64
    OrganizationId string
    A UUID representing an organization.
    PatsEnabled bool
    max_expiration_period_days number
    organization_id string
    A UUID representing an organization.
    pats_enabled bool
    maxExpirationPeriodDays Double
    organizationId String
    A UUID representing an organization.
    patsEnabled Boolean
    maxExpirationPeriodDays number
    organizationId string
    A UUID representing an organization.
    patsEnabled boolean
    max_expiration_period_days float
    organization_id str
    A UUID representing an organization.
    pats_enabled bool
    maxExpirationPeriodDays Number
    organizationId String
    A UUID representing an organization.
    patsEnabled Boolean

    Import

    In Terraform v1.5.0 and later, the import block can be used with the id attribute, for example:

    terraform

    import {

    to = konnect_organization_personal_access_token_settings.my_konnect_organization_personal_access_token_settings

    id = “5f9fd312-a987-4628-b4c5-bb4f4fddd5f7”

    }

    The pulumi import command can be used, for example:

    $ pulumi import konnect:index/organizationPersonalAccessTokenSettings:OrganizationPersonalAccessTokenSettings my_konnect_organization_personal_access_token_settings "5f9fd312-a987-4628-b4c5-bb4f4fddd5f7"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    konnect kong/terraform-provider-konnect
    License
    Notes
    This Pulumi package is based on the konnect Terraform Provider.
    Viewing docs for konnect 3.21.0
    published on Tuesday, Aug 4, 2026 by kong

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial