1. Packages
  2. Coralogix Provider
  3. API Docs
  4. getApiKey
coralogix 2.0.16 published on Monday, Apr 14, 2025 by coralogix

coralogix.getApiKey

Explore with Pulumi AI

coralogix 2.0.16 published on Monday, Apr 14, 2025 by coralogix

Coralogix Api keys.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as coralogix from "@pulumi/coralogix";

const sameKeyById = coralogix.getApiKey({
    id: coralogix_api_key.example.id,
});
Copy
import pulumi
import pulumi_coralogix as coralogix

same_key_by_id = coralogix.get_api_key(id=coralogix_api_key["example"]["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/coralogix/v2/coralogix"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := coralogix.LookupApiKey(ctx, &coralogix.LookupApiKeyArgs{
			Id: coralogix_api_key.Example.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Coralogix = Pulumi.Coralogix;

return await Deployment.RunAsync(() => 
{
    var sameKeyById = Coralogix.GetApiKey.Invoke(new()
    {
        Id = coralogix_api_key.Example.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.coralogix.CoralogixFunctions;
import com.pulumi.coralogix.inputs.GetApiKeyArgs;
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 sameKeyById = CoralogixFunctions.getApiKey(GetApiKeyArgs.builder()
            .id(coralogix_api_key.example().id())
            .build());

    }
}
Copy
variables:
  sameKeyById:
    fn::invoke:
      function: coralogix:getApiKey
      arguments:
        id: ${coralogix_api_key.example.id}
Copy

Using getApiKey

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 getApiKey(args: GetApiKeyArgs, opts?: InvokeOptions): Promise<GetApiKeyResult>
function getApiKeyOutput(args: GetApiKeyOutputArgs, opts?: InvokeOptions): Output<GetApiKeyResult>
Copy
def get_api_key(id: Optional[str] = None,
                opts: Optional[InvokeOptions] = None) -> GetApiKeyResult
def get_api_key_output(id: Optional[pulumi.Input[str]] = None,
                opts: Optional[InvokeOptions] = None) -> Output[GetApiKeyResult]
Copy
func LookupApiKey(ctx *Context, args *LookupApiKeyArgs, opts ...InvokeOption) (*LookupApiKeyResult, error)
func LookupApiKeyOutput(ctx *Context, args *LookupApiKeyOutputArgs, opts ...InvokeOption) LookupApiKeyResultOutput
Copy

> Note: This function is named LookupApiKey in the Go SDK.

public static class GetApiKey 
{
    public static Task<GetApiKeyResult> InvokeAsync(GetApiKeyArgs args, InvokeOptions? opts = null)
    public static Output<GetApiKeyResult> Invoke(GetApiKeyInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetApiKeyResult> getApiKey(GetApiKeyArgs args, InvokeOptions options)
public static Output<GetApiKeyResult> getApiKey(GetApiKeyArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: coralogix:index/getApiKey:getApiKey
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Id This property is required. string
ApiKey ID.
Id This property is required. string
ApiKey ID.
id This property is required. String
ApiKey ID.
id This property is required. string
ApiKey ID.
id This property is required. str
ApiKey ID.
id This property is required. String
ApiKey ID.

getApiKey Result

The following output properties are available:

Active bool
Api Key Is Active.
Hashed bool
Api Key Is Hashed.
Id string
ApiKey ID.
Name string
Api Key name.
Owner GetApiKeyOwner
Api Key Owner. It can either be a teamid, organisationid, or a user_id
Permissions List<string>
Api Key Permissions
Presets List<string>
Api Key Presets
Value string
Api Key value.
Active bool
Api Key Is Active.
Hashed bool
Api Key Is Hashed.
Id string
ApiKey ID.
Name string
Api Key name.
Owner GetApiKeyOwner
Api Key Owner. It can either be a teamid, organisationid, or a user_id
Permissions []string
Api Key Permissions
Presets []string
Api Key Presets
Value string
Api Key value.
active Boolean
Api Key Is Active.
hashed Boolean
Api Key Is Hashed.
id String
ApiKey ID.
name String
Api Key name.
owner GetApiKeyOwner
Api Key Owner. It can either be a teamid, organisationid, or a user_id
permissions List<String>
Api Key Permissions
presets List<String>
Api Key Presets
value String
Api Key value.
active boolean
Api Key Is Active.
hashed boolean
Api Key Is Hashed.
id string
ApiKey ID.
name string
Api Key name.
owner GetApiKeyOwner
Api Key Owner. It can either be a teamid, organisationid, or a user_id
permissions string[]
Api Key Permissions
presets string[]
Api Key Presets
value string
Api Key value.
active bool
Api Key Is Active.
hashed bool
Api Key Is Hashed.
id str
ApiKey ID.
name str
Api Key name.
owner GetApiKeyOwner
Api Key Owner. It can either be a teamid, organisationid, or a user_id
permissions Sequence[str]
Api Key Permissions
presets Sequence[str]
Api Key Presets
value str
Api Key value.
active Boolean
Api Key Is Active.
hashed Boolean
Api Key Is Hashed.
id String
ApiKey ID.
name String
Api Key name.
owner Property Map
Api Key Owner. It can either be a teamid, organisationid, or a user_id
permissions List<String>
Api Key Permissions
presets List<String>
Api Key Presets
value String
Api Key value.

Supporting Types

GetApiKeyOwner

OrganisationId This property is required. string
TeamId This property is required. string
UserId This property is required. string
OrganisationId This property is required. string
TeamId This property is required. string
UserId This property is required. string
organisationId This property is required. String
teamId This property is required. String
userId This property is required. String
organisationId This property is required. string
teamId This property is required. string
userId This property is required. string
organisation_id This property is required. str
team_id This property is required. str
user_id This property is required. str
organisationId This property is required. String
teamId This property is required. String
userId This property is required. String

Package Details

Repository
coralogix coralogix/terraform-provider-coralogix
License
Notes
This Pulumi package is based on the coralogix Terraform Provider.
coralogix 2.0.16 published on Monday, Apr 14, 2025 by coralogix