Oracle Cloud Infrastructure v3.7.0 published on Saturday, Sep 13, 2025 by Pulumi
oci.ManagementAgent.getNamedCredentials
Explore with Pulumi AI
This data source provides the list of Named Credentials in Oracle Cloud Infrastructure Management Agent service.
A list of Management Agent Data Sources for the given Management Agent Id.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testNamedCredentials = oci.ManagementAgent.getNamedCredentials({
managementAgentId: testManagementAgent.id,
ids: [namedCredentialId],
names: [namedCredentialName],
states: [namedCredentialState],
types: [namedCredentialType],
});
import pulumi
import pulumi_oci as oci
test_named_credentials = oci.ManagementAgent.get_named_credentials(management_agent_id=test_management_agent["id"],
ids=[named_credential_id],
names=[named_credential_name],
states=[named_credential_state],
types=[named_credential_type])
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/managementagent"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := managementagent.GetNamedCredentials(ctx, &managementagent.GetNamedCredentialsArgs{
ManagementAgentId: testManagementAgent.Id,
Ids: interface{}{
namedCredentialId,
},
Names: interface{}{
namedCredentialName,
},
States: interface{}{
namedCredentialState,
},
Types: interface{}{
namedCredentialType,
},
}, nil);
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() =>
{
var testNamedCredentials = Oci.ManagementAgent.GetNamedCredentials.Invoke(new()
{
ManagementAgentId = testManagementAgent.Id,
Ids = new[]
{
namedCredentialId,
},
Names = new[]
{
namedCredentialName,
},
States = new[]
{
namedCredentialState,
},
Types = new[]
{
namedCredentialType,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.ManagementAgent.ManagementAgentFunctions;
import com.pulumi.oci.ManagementAgent.inputs.GetNamedCredentialsArgs;
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) {
final var testNamedCredentials = ManagementAgentFunctions.getNamedCredentials(GetNamedCredentialsArgs.builder()
.managementAgentId(testManagementAgent.id())
.ids(namedCredentialId)
.names(namedCredentialName)
.states(namedCredentialState)
.types(namedCredentialType)
.build());
}
}
variables:
testNamedCredentials:
fn::invoke:
function: oci:ManagementAgent:getNamedCredentials
arguments:
managementAgentId: ${testManagementAgent.id}
ids:
- ${namedCredentialId}
names:
- ${namedCredentialName}
states:
- ${namedCredentialState}
types:
- ${namedCredentialType}
Using getNamedCredentials
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 getNamedCredentials(args: GetNamedCredentialsArgs, opts?: InvokeOptions): Promise<GetNamedCredentialsResult>
function getNamedCredentialsOutput(args: GetNamedCredentialsOutputArgs, opts?: InvokeOptions): Output<GetNamedCredentialsResult>
def get_named_credentials(filters: Optional[Sequence[GetNamedCredentialsFilter]] = None,
ids: Optional[Sequence[str]] = None,
management_agent_id: Optional[str] = None,
names: Optional[Sequence[str]] = None,
states: Optional[Sequence[str]] = None,
types: Optional[Sequence[str]] = None,
opts: Optional[InvokeOptions] = None) -> GetNamedCredentialsResult
def get_named_credentials_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetNamedCredentialsFilterArgs]]]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
management_agent_id: Optional[pulumi.Input[str]] = None,
names: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
states: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
types: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetNamedCredentialsResult]
func GetNamedCredentials(ctx *Context, args *GetNamedCredentialsArgs, opts ...InvokeOption) (*GetNamedCredentialsResult, error)
func GetNamedCredentialsOutput(ctx *Context, args *GetNamedCredentialsOutputArgs, opts ...InvokeOption) GetNamedCredentialsResultOutput
> Note: This function is named GetNamedCredentials
in the Go SDK.
public static class GetNamedCredentials
{
public static Task<GetNamedCredentialsResult> InvokeAsync(GetNamedCredentialsArgs args, InvokeOptions? opts = null)
public static Output<GetNamedCredentialsResult> Invoke(GetNamedCredentialsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetNamedCredentialsResult> getNamedCredentials(GetNamedCredentialsArgs args, InvokeOptions options)
public static Output<GetNamedCredentialsResult> getNamedCredentials(GetNamedCredentialsArgs args, InvokeOptions options)
fn::invoke:
function: oci:ManagementAgent/getNamedCredentials:getNamedCredentials
arguments:
# arguments dictionary
The following arguments are supported:
- Management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- Filters
List<Get
Named Credentials Filter> - Ids List<string>
- Filter list for these Named credentials identifiers (ocid) values.
- Names List<string>
- Filter list for these name items.
- States List<string>
- Filter list to return only Management Agents in the particular lifecycle state.
- Types List<string>
- Filter list for these type values.
- Management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- Filters
[]Get
Named Credentials Filter - Ids []string
- Filter list for these Named credentials identifiers (ocid) values.
- Names []string
- Filter list for these name items.
- States []string
- Filter list to return only Management Agents in the particular lifecycle state.
- Types []string
- Filter list for these type values.
- management
Agent StringId - The ManagementAgentID of the agent from which the named credentials are associated.
- filters
List<Get
Named Credentials Filter> - ids List<String>
- Filter list for these Named credentials identifiers (ocid) values.
- names List<String>
- Filter list for these name items.
- states List<String>
- Filter list to return only Management Agents in the particular lifecycle state.
- types List<String>
- Filter list for these type values.
- management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- filters
Get
Named Credentials Filter[] - ids string[]
- Filter list for these Named credentials identifiers (ocid) values.
- names string[]
- Filter list for these name items.
- states string[]
- Filter list to return only Management Agents in the particular lifecycle state.
- types string[]
- Filter list for these type values.
- management_
agent_ strid - The ManagementAgentID of the agent from which the named credentials are associated.
- filters
Sequence[Get
Named Credentials Filter] - ids Sequence[str]
- Filter list for these Named credentials identifiers (ocid) values.
- names Sequence[str]
- Filter list for these name items.
- states Sequence[str]
- Filter list to return only Management Agents in the particular lifecycle state.
- types Sequence[str]
- Filter list for these type values.
- management
Agent StringId - The ManagementAgentID of the agent from which the named credentials are associated.
- filters List<Property Map>
- ids List<String>
- Filter list for these Named credentials identifiers (ocid) values.
- names List<String>
- Filter list for these name items.
- states List<String>
- Filter list to return only Management Agents in the particular lifecycle state.
- types List<String>
- Filter list for these type values.
getNamedCredentials Result
The following output properties are available:
- Management
Agent stringId - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- Named
Credential List<GetCollections Named Credentials Named Credential Collection> - The list of named_credential_collection.
- Filters
List<Get
Named Credentials Filter> - Ids List<string>
- Identifier for Named Credential.
- Names List<string>
- Name of the property
- States List<string>
- The current state of the named credential
- Types List<string>
- The type of the Named Credential.
- Management
Agent stringId - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- Named
Credential []GetCollections Named Credentials Named Credential Collection - The list of named_credential_collection.
- Filters
[]Get
Named Credentials Filter - Ids []string
- Identifier for Named Credential.
- Names []string
- Name of the property
- States []string
- The current state of the named credential
- Types []string
- The type of the Named Credential.
- management
Agent StringId - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- named
Credential List<GetCollections Named Credentials Named Credential Collection> - The list of named_credential_collection.
- filters
List<Get
Named Credentials Filter> - ids List<String>
- Identifier for Named Credential.
- names List<String>
- Name of the property
- states List<String>
- The current state of the named credential
- types List<String>
- The type of the Named Credential.
- management
Agent stringId - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- named
Credential GetCollections Named Credentials Named Credential Collection[] - The list of named_credential_collection.
- filters
Get
Named Credentials Filter[] - ids string[]
- Identifier for Named Credential.
- names string[]
- Name of the property
- states string[]
- The current state of the named credential
- types string[]
- The type of the Named Credential.
- management_
agent_ strid - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- named_
credential_ Sequence[Getcollections Named Credentials Named Credential Collection] - The list of named_credential_collection.
- filters
Sequence[Get
Named Credentials Filter] - ids Sequence[str]
- Identifier for Named Credential.
- names Sequence[str]
- Name of the property
- states Sequence[str]
- The current state of the named credential
- types Sequence[str]
- The type of the Named Credential.
- management
Agent StringId - The Management Agent parent resource to associated with this named credential. This is the ManagementAgent resource OCID.
- named
Credential List<Property Map>Collections - The list of named_credential_collection.
- filters List<Property Map>
- ids List<String>
- Identifier for Named Credential.
- names List<String>
- Name of the property
- states List<String>
- The current state of the named credential
- types List<String>
- The type of the Named Credential.
Supporting Types
GetNamedCredentialsFilter
GetNamedCredentialsNamedCredentialCollection
GetNamedCredentialsNamedCredentialCollectionItem
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
- Description of the Named Credential.
- Dictionary<string, string>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- Id string
- Filter list for these Named credentials identifiers (ocid) values.
- Management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- Name string
- Filter list for these name items.
- Properties
List<Get
Named Credentials Named Credential Collection Item Property> - Properties for the named credential
- State string
- Filter list to return only Management Agents in the particular lifecycle state.
- Dictionary<string, string>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- Time
Created string - The time the Named Credential was created. An RFC3339 formatted datetime string
- Time
Updated string - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- Type string
- Filter list for these type values.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- Description string
- Description of the Named Credential.
- map[string]string
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- Id string
- Filter list for these Named credentials identifiers (ocid) values.
- Management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- Name string
- Filter list for these name items.
- Properties
[]Get
Named Credentials Named Credential Collection Item Property - Properties for the named credential
- State string
- Filter list to return only Management Agents in the particular lifecycle state.
- map[string]string
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- Time
Created string - The time the Named Credential was created. An RFC3339 formatted datetime string
- Time
Updated string - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- Type string
- Filter list for these type values.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
- Description of the Named Credential.
- Map<String,String>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id String
- Filter list for these Named credentials identifiers (ocid) values.
- management
Agent StringId - The ManagementAgentID of the agent from which the named credentials are associated.
- name String
- Filter list for these name items.
- properties
List<Get
Named Credentials Named Credential Collection Item Property> - Properties for the named credential
- state String
- Filter list to return only Management Agents in the particular lifecycle state.
- Map<String,String>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- time
Created String - The time the Named Credential was created. An RFC3339 formatted datetime string
- time
Updated String - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- type String
- Filter list for these type values.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description string
- Description of the Named Credential.
- {[key: string]: string}
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id string
- Filter list for these Named credentials identifiers (ocid) values.
- management
Agent stringId - The ManagementAgentID of the agent from which the named credentials are associated.
- name string
- Filter list for these name items.
- properties
Get
Named Credentials Named Credential Collection Item Property[] - Properties for the named credential
- state string
- Filter list to return only Management Agents in the particular lifecycle state.
- {[key: string]: string}
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- time
Created string - The time the Named Credential was created. An RFC3339 formatted datetime string
- time
Updated string - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- type string
- Filter list for these type values.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description str
- Description of the Named Credential.
- Mapping[str, str]
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id str
- Filter list for these Named credentials identifiers (ocid) values.
- management_
agent_ strid - The ManagementAgentID of the agent from which the named credentials are associated.
- name str
- Filter list for these name items.
- properties
Sequence[Get
Named Credentials Named Credential Collection Item Property] - Properties for the named credential
- state str
- Filter list to return only Management Agents in the particular lifecycle state.
- Mapping[str, str]
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- time_
created str - The time the Named Credential was created. An RFC3339 formatted datetime string
- time_
updated str - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- type str
- Filter list for these type values.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
- description String
- Description of the Named Credential.
- Map<String>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id String
- Filter list for these Named credentials identifiers (ocid) values.
- management
Agent StringId - The ManagementAgentID of the agent from which the named credentials are associated.
- name String
- Filter list for these name items.
- properties List<Property Map>
- Properties for the named credential
- state String
- Filter list to return only Management Agents in the particular lifecycle state.
- Map<String>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
- time
Created String - The time the Named Credential was created. An RFC3339 formatted datetime string
- time
Updated String - The time the Named Credential data was last updated. An RFC3339 formatted datetime string
- type String
- Filter list for these type values.
GetNamedCredentialsNamedCredentialCollectionItemProperty
- Name string
- Filter list for these name items.
- Value string
- Value of the property
- Value
Category string - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
- Name string
- Filter list for these name items.
- Value string
- Value of the property
- Value
Category string - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
- name String
- Filter list for these name items.
- value String
- Value of the property
- value
Category String - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
- name string
- Filter list for these name items.
- value string
- Value of the property
- value
Category string - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
- name str
- Filter list for these name items.
- value str
- Value of the property
- value_
category str - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
- name String
- Filter list for these name items.
- value String
- Value of the property
- value
Category String - The category of the Named credential property value. CLEAR_TEXT indicates the value field contains a clear text value. SECRET_IDENTIFIER indicates the value field contains a vault secret ocid identifier. ADB_IDENTIFIER indicates the value field contains an Autonomous database ocid identifier. ALLOWED_VALUE indicates the value should be selected from the options in the allowedValues field.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.