AppOauthApiScope

Manages API scopes for OAuth applications.

This resource allows you to grant or revoke API scopes for OAuth2 applications within your organization.

import * as pulumi from "@pulumi/pulumi";
import pulumi
using Pulumi;

class MyStack : Stack
{
    public MyStack()
    {
    }

}
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		return nil
	})
}

Example Usage

using Pulumi;
using Okta = Pulumi.Okta;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Okta.AppOauthApiScope("example", new Okta.AppOauthApiScopeArgs
        {
            AppId = "<application_id>",
            Issuer = "<your org domain>",
            Scopes = 
            {
                "okta.users.read",
                "okta.users.manage",
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-okta/sdk/v3/go/okta"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := okta.NewAppOauthApiScope(ctx, "example", &okta.AppOauthApiScopeArgs{
			AppId:  pulumi.String("<application_id>"),
			Issuer: pulumi.String("<your org domain>"),
			Scopes: pulumi.StringArray{
				pulumi.String("okta.users.read"),
				pulumi.String("okta.users.manage"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
import pulumi
import pulumi_okta as okta

example = okta.AppOauthApiScope("example",
    app_id="<application_id>",
    issuer="<your org domain>",
    scopes=[
        "okta.users.read",
        "okta.users.manage",
    ])
import * as pulumi from "@pulumi/pulumi";
import * as okta from "@pulumi/okta";

const example = new okta.AppOauthApiScope("example", {
    appId: "<application_id>",
    issuer: "<your org domain>",
    scopes: [
        "okta.users.read",
        "okta.users.manage",
    ],
});

Create a AppOauthApiScope Resource

new AppOauthApiScope(name: string, args: AppOauthApiScopeArgs, opts?: CustomResourceOptions);
@overload
def AppOauthApiScope(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     app_id: Optional[str] = None,
                     issuer: Optional[str] = None,
                     scopes: Optional[Sequence[str]] = None)
@overload
def AppOauthApiScope(resource_name: str,
                     args: AppOauthApiScopeArgs,
                     opts: Optional[ResourceOptions] = None)
func NewAppOauthApiScope(ctx *Context, name string, args AppOauthApiScopeArgs, opts ...ResourceOption) (*AppOauthApiScope, error)
public AppOauthApiScope(string name, AppOauthApiScopeArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args AppOauthApiScopeArgs
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 AppOauthApiScopeArgs
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 AppOauthApiScopeArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AppOauthApiScopeArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

AppOauthApiScope Resource Properties

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

Inputs

The AppOauthApiScope resource accepts the following input properties:

AppId string
ID of the application.
Issuer string
The issuer of your Org Authorization Server, your Org URL.
Scopes List<string>
List of scopes for which consent is granted.
AppId string
ID of the application.
Issuer string
The issuer of your Org Authorization Server, your Org URL.
Scopes []string
List of scopes for which consent is granted.
appId string
ID of the application.
issuer string
The issuer of your Org Authorization Server, your Org URL.
scopes string[]
List of scopes for which consent is granted.
app_id str
ID of the application.
issuer str
The issuer of your Org Authorization Server, your Org URL.
scopes Sequence[str]
List of scopes for which consent is granted.

Outputs

All input properties are implicitly available as output properties. Additionally, the AppOauthApiScope 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 str
The provider-assigned unique ID for this managed resource.

Look up an Existing AppOauthApiScope Resource

Get an existing AppOauthApiScope 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?: AppOauthApiScopeState, opts?: CustomResourceOptions): AppOauthApiScope
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        app_id: Optional[str] = None,
        issuer: Optional[str] = None,
        scopes: Optional[Sequence[str]] = None) -> AppOauthApiScope
func GetAppOauthApiScope(ctx *Context, name string, id IDInput, state *AppOauthApiScopeState, opts ...ResourceOption) (*AppOauthApiScope, error)
public static AppOauthApiScope Get(string name, Input<string> id, AppOauthApiScopeState? state, CustomResourceOptions? opts = null)
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.

The following state arguments are supported:

AppId string
ID of the application.
Issuer string
The issuer of your Org Authorization Server, your Org URL.
Scopes List<string>
List of scopes for which consent is granted.
AppId string
ID of the application.
Issuer string
The issuer of your Org Authorization Server, your Org URL.
Scopes []string
List of scopes for which consent is granted.
appId string
ID of the application.
issuer string
The issuer of your Org Authorization Server, your Org URL.
scopes string[]
List of scopes for which consent is granted.
app_id str
ID of the application.
issuer str
The issuer of your Org Authorization Server, your Org URL.
scopes Sequence[str]
List of scopes for which consent is granted.

Import

OAuth API scopes can be imported via the Okta Application ID.

 $ pulumi import okta:index/appOauthApiScope:AppOauthApiScope example <app id>

Package Details

Repository
https://github.com/pulumi/pulumi-okta
License
Apache-2.0
Notes
This Pulumi package is based on the okta Terraform Provider.