Auth0 v3.8.3 published on Wednesday, Nov 6, 2024 by Pulumi
auth0.getResourceServer
Explore with Pulumi AI
Data source to retrieve a specific Auth0 resource server by resource_server_id
or identifier
.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as auth0 from "@pulumi/auth0";
// An Auth0 Resource Server loaded using its identifier.
const some-resource-server-by-identifier = auth0.getResourceServer({
identifier: "https://my-api.com/v1",
});
// An Auth0 Resource Server loaded using its ID.
const some-resource-server-by-id = auth0.getResourceServer({
resourceServerId: "abcdefghkijklmnopqrstuvwxyz0123456789",
});
import pulumi
import pulumi_auth0 as auth0
# An Auth0 Resource Server loaded using its identifier.
some_resource_server_by_identifier = auth0.get_resource_server(identifier="https://my-api.com/v1")
# An Auth0 Resource Server loaded using its ID.
some_resource_server_by_id = auth0.get_resource_server(resource_server_id="abcdefghkijklmnopqrstuvwxyz0123456789")
package main
import (
"github.com/pulumi/pulumi-auth0/sdk/v3/go/auth0"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
// An Auth0 Resource Server loaded using its identifier.
_, err := auth0.LookupResourceServer(ctx, &auth0.LookupResourceServerArgs{
Identifier: pulumi.StringRef("https://my-api.com/v1"),
}, nil)
if err != nil {
return err
}
// An Auth0 Resource Server loaded using its ID.
_, err = auth0.LookupResourceServer(ctx, &auth0.LookupResourceServerArgs{
ResourceServerId: pulumi.StringRef("abcdefghkijklmnopqrstuvwxyz0123456789"),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Auth0 = Pulumi.Auth0;
return await Deployment.RunAsync(() =>
{
// An Auth0 Resource Server loaded using its identifier.
var some_resource_server_by_identifier = Auth0.GetResourceServer.Invoke(new()
{
Identifier = "https://my-api.com/v1",
});
// An Auth0 Resource Server loaded using its ID.
var some_resource_server_by_id = Auth0.GetResourceServer.Invoke(new()
{
ResourceServerId = "abcdefghkijklmnopqrstuvwxyz0123456789",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.auth0.Auth0Functions;
import com.pulumi.auth0.inputs.GetResourceServerArgs;
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) {
// An Auth0 Resource Server loaded using its identifier.
final var some-resource-server-by-identifier = Auth0Functions.getResourceServer(GetResourceServerArgs.builder()
.identifier("https://my-api.com/v1")
.build());
// An Auth0 Resource Server loaded using its ID.
final var some-resource-server-by-id = Auth0Functions.getResourceServer(GetResourceServerArgs.builder()
.resourceServerId("abcdefghkijklmnopqrstuvwxyz0123456789")
.build());
}
}
variables:
# An Auth0 Resource Server loaded using its identifier.
some-resource-server-by-identifier:
fn::invoke:
Function: auth0:getResourceServer
Arguments:
identifier: https://my-api.com/v1
# An Auth0 Resource Server loaded using its ID.
some-resource-server-by-id:
fn::invoke:
Function: auth0:getResourceServer
Arguments:
resourceServerId: abcdefghkijklmnopqrstuvwxyz0123456789
Using getResourceServer
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getResourceServer(args: GetResourceServerArgs, opts?: InvokeOptions): Promise<GetResourceServerResult>
function getResourceServerOutput(args: GetResourceServerOutputArgs, opts?: InvokeOptions): Output<GetResourceServerResult>
def get_resource_server(identifier: Optional[str] = None,
resource_server_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetResourceServerResult
def get_resource_server_output(identifier: Optional[pulumi.Input[str]] = None,
resource_server_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetResourceServerResult]
func LookupResourceServer(ctx *Context, args *LookupResourceServerArgs, opts ...InvokeOption) (*LookupResourceServerResult, error)
func LookupResourceServerOutput(ctx *Context, args *LookupResourceServerOutputArgs, opts ...InvokeOption) LookupResourceServerResultOutput
> Note: This function is named LookupResourceServer
in the Go SDK.
public static class GetResourceServer
{
public static Task<GetResourceServerResult> InvokeAsync(GetResourceServerArgs args, InvokeOptions? opts = null)
public static Output<GetResourceServerResult> Invoke(GetResourceServerInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetResourceServerResult> getResourceServer(GetResourceServerArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: auth0:index/getResourceServer:getResourceServer
arguments:
# arguments dictionary
The following arguments are supported:
- Identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - Resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- Identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - Resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- identifier String
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server StringId - The ID of the resource server. If not provided,
identifier
must be set.
- identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- identifier str
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource_
server_ strid - The ID of the resource server. If not provided,
identifier
must be set.
- identifier String
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server StringId - The ID of the resource server. If not provided,
identifier
must be set.
getResourceServer Result
The following output properties are available:
- Allow
Offline boolAccess - Indicates whether refresh tokens can be issued for this resource server.
- List<Get
Resource Server Authorization Detail> - Authorization details for this resource server.
- Consent
Policy string - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - Enforce
Policies bool - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Friendly name for the resource server. Cannot include
<
or>
characters. - Proof
Of List<GetPossessions Resource Server Proof Of Possession> - Configuration settings for proof-of-possession for this resource server.
- Scopes
List<Get
Resource Server Scope> - List of permissions (scopes) used by this resource server.
- Signing
Alg string - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - Signing
Secret string - Secret used to sign tokens when using symmetric algorithms (HS256).
- Skip
Consent boolFor Verifiable First Party Clients - Indicates whether to skip user consent for applications flagged as first party.
- Token
Dialect string - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - Token
Encryptions List<GetResource Server Token Encryption> - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- Token
Lifetime int - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- Token
Lifetime intFor Web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - Verification
Location string - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- Identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - Resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- Allow
Offline boolAccess - Indicates whether refresh tokens can be issued for this resource server.
- []Get
Resource Server Authorization Detail - Authorization details for this resource server.
- Consent
Policy string - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - Enforce
Policies bool - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Friendly name for the resource server. Cannot include
<
or>
characters. - Proof
Of []GetPossessions Resource Server Proof Of Possession - Configuration settings for proof-of-possession for this resource server.
- Scopes
[]Get
Resource Server Scope Type - List of permissions (scopes) used by this resource server.
- Signing
Alg string - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - Signing
Secret string - Secret used to sign tokens when using symmetric algorithms (HS256).
- Skip
Consent boolFor Verifiable First Party Clients - Indicates whether to skip user consent for applications flagged as first party.
- Token
Dialect string - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - Token
Encryptions []GetResource Server Token Encryption - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- Token
Lifetime int - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- Token
Lifetime intFor Web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - Verification
Location string - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- Identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - Resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- allow
Offline BooleanAccess - Indicates whether refresh tokens can be issued for this resource server.
- List<Get
Resource Server Authorization Detail> - Authorization details for this resource server.
- consent
Policy String - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - enforce
Policies Boolean - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- Friendly name for the resource server. Cannot include
<
or>
characters. - proof
Of List<GetPossessions Resource Server Proof Of Possession> - Configuration settings for proof-of-possession for this resource server.
- scopes
List<Get
Resource Server Scope> - List of permissions (scopes) used by this resource server.
- signing
Alg String - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - signing
Secret String - Secret used to sign tokens when using symmetric algorithms (HS256).
- skip
Consent BooleanFor Verifiable First Party Clients - Indicates whether to skip user consent for applications flagged as first party.
- token
Dialect String - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - token
Encryptions List<GetResource Server Token Encryption> - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- token
Lifetime Integer - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- token
Lifetime IntegerFor Web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - verification
Location String - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- identifier String
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server StringId - The ID of the resource server. If not provided,
identifier
must be set.
- allow
Offline booleanAccess - Indicates whether refresh tokens can be issued for this resource server.
- Get
Resource Server Authorization Detail[] - Authorization details for this resource server.
- consent
Policy string - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - enforce
Policies boolean - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- Friendly name for the resource server. Cannot include
<
or>
characters. - proof
Of GetPossessions Resource Server Proof Of Possession[] - Configuration settings for proof-of-possession for this resource server.
- scopes
Get
Resource Server Scope[] - List of permissions (scopes) used by this resource server.
- signing
Alg string - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - signing
Secret string - Secret used to sign tokens when using symmetric algorithms (HS256).
- skip
Consent booleanFor Verifiable First Party Clients - Indicates whether to skip user consent for applications flagged as first party.
- token
Dialect string - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - token
Encryptions GetResource Server Token Encryption[] - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- token
Lifetime number - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- token
Lifetime numberFor Web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - verification
Location string - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- identifier string
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server stringId - The ID of the resource server. If not provided,
identifier
must be set.
- allow_
offline_ boolaccess - Indicates whether refresh tokens can be issued for this resource server.
- Sequence[Get
Resource Server Authorization Detail] - Authorization details for this resource server.
- consent_
policy str - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - enforce_
policies bool - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- Friendly name for the resource server. Cannot include
<
or>
characters. - proof_
of_ Sequence[Getpossessions Resource Server Proof Of Possession] - Configuration settings for proof-of-possession for this resource server.
- scopes
Sequence[Get
Resource Server Scope] - List of permissions (scopes) used by this resource server.
- signing_
alg str - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - signing_
secret str - Secret used to sign tokens when using symmetric algorithms (HS256).
- skip_
consent_ boolfor_ verifiable_ first_ party_ clients - Indicates whether to skip user consent for applications flagged as first party.
- token_
dialect str - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - token_
encryptions Sequence[GetResource Server Token Encryption] - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- token_
lifetime int - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- token_
lifetime_ intfor_ web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - verification_
location str - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- identifier str
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource_
server_ strid - The ID of the resource server. If not provided,
identifier
must be set.
- allow
Offline BooleanAccess - Indicates whether refresh tokens can be issued for this resource server.
- List<Property Map>
- Authorization details for this resource server.
- consent
Policy String - Consent policy for this resource server. Options include
transactional-authorization-with-mfa
, ornull
to disable. - enforce
Policies Boolean - If this setting is enabled, RBAC authorization policies will be enforced for this API. Role and permission assignments will be evaluated during the login transaction.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- Friendly name for the resource server. Cannot include
<
or>
characters. - proof
Of List<Property Map>Possessions - Configuration settings for proof-of-possession for this resource server.
- scopes List<Property Map>
- List of permissions (scopes) used by this resource server.
- signing
Alg String - Algorithm used to sign JWTs. Options include
HS256
,RS256
, andPS256
. - signing
Secret String - Secret used to sign tokens when using symmetric algorithms (HS256).
- skip
Consent BooleanFor Verifiable First Party Clients - Indicates whether to skip user consent for applications flagged as first party.
- token
Dialect String - Dialect of access tokens that should be issued for this resource server. Options include
access_token
,rfc9068_profile
,access_token_authz
, andrfc9068_profile_authz
.access_token
is a JWT containing standard Auth0 claims.rfc9068_profile
is a JWT conforming to the IETF JWT Access Token Profile.access_token_authz
is a JWT containing standard Auth0 claims, including RBAC permissions claims.rfc9068_profile_authz
is a JWT conforming to the IETF JWT Access Token Profile, including RBAC permissions claims. RBAC permissions claims are available if RBAC (enforce_policies
) is enabled for this API. For more details, refer to Access Token Profiles. - token
Encryptions List<Property Map> - Configuration for JSON Web Encryption(JWE) of tokens for this resource server.
- token
Lifetime Number - Number of seconds during which access tokens issued for this resource server from the token endpoint remain valid.
- token
Lifetime NumberFor Web - Number of seconds during which access tokens issued for this resource server via implicit or hybrid flows remain valid. Cannot be greater than the
token_lifetime
value. - verification
Location String - URL from which to retrieve JWKs for this resource server. Used for verifying the JWT sent to Auth0 for token introspection.
- identifier String
- Unique identifier for the resource server. Used as the audience parameter for authorization calls. If not provided,
resource_server_id
must be set. - resource
Server StringId - The ID of the resource server. If not provided,
identifier
must be set.
Supporting Types
GetResourceServerAuthorizationDetail
GetResourceServerProofOfPossession
GetResourceServerScope
- Description string
- Description of the permission (scope).
- Name string
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
- Description string
- Description of the permission (scope).
- Name string
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
- description String
- Description of the permission (scope).
- name String
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
- description string
- Description of the permission (scope).
- name string
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
- description str
- Description of the permission (scope).
- name str
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
- description String
- Description of the permission (scope).
- name String
- Name of the permission (scope). Examples include
read:appointments
ordelete:appointments
.
GetResourceServerTokenEncryption
- Disable bool
- Disable token encryption.
- Encryption
Keys List<GetResource Server Token Encryption Encryption Key> - Authorization details for this resource server.
- Format string
- Format of the token encryption. Only
compact-nested-jwe
is supported.
- Disable bool
- Disable token encryption.
- Encryption
Keys []GetResource Server Token Encryption Encryption Key - Authorization details for this resource server.
- Format string
- Format of the token encryption. Only
compact-nested-jwe
is supported.
- disable Boolean
- Disable token encryption.
- encryption
Keys List<GetResource Server Token Encryption Encryption Key> - Authorization details for this resource server.
- format String
- Format of the token encryption. Only
compact-nested-jwe
is supported.
- disable boolean
- Disable token encryption.
- encryption
Keys GetResource Server Token Encryption Encryption Key[] - Authorization details for this resource server.
- format string
- Format of the token encryption. Only
compact-nested-jwe
is supported.
- disable bool
- Disable token encryption.
- encryption_
keys Sequence[GetResource Server Token Encryption Encryption Key] - Authorization details for this resource server.
- format str
- Format of the token encryption. Only
compact-nested-jwe
is supported.
- disable Boolean
- Disable token encryption.
- encryption
Keys List<Property Map> - Authorization details for this resource server.
- format String
- Format of the token encryption. Only
compact-nested-jwe
is supported.
GetResourceServerTokenEncryptionEncryptionKey
Package Details
- Repository
- Auth0 pulumi/pulumi-auth0
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
auth0
Terraform Provider.