Oracle Cloud Infrastructure v2.33.0 published on Thursday, May 1, 2025 by Pulumi
oci.Artifacts.getGenericArtifact
Explore with Pulumi AI
This data source provides details about a specific Generic Artifact resource in Oracle Cloud Infrastructure Artifacts service.
Gets information about an artifact with a specified OCID.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testGenericArtifact = oci.Artifacts.getGenericArtifact({
    artifactId: testArtifact.id,
});
import pulumi
import pulumi_oci as oci
test_generic_artifact = oci.Artifacts.get_generic_artifact(artifact_id=test_artifact["id"])
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/artifacts"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := artifacts.GetGenericArtifact(ctx, &artifacts.GetGenericArtifactArgs{
			ArtifactId: testArtifact.Id,
		}, 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 testGenericArtifact = Oci.Artifacts.GetGenericArtifact.Invoke(new()
    {
        ArtifactId = testArtifact.Id,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Artifacts.ArtifactsFunctions;
import com.pulumi.oci.Artifacts.inputs.GetGenericArtifactArgs;
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 testGenericArtifact = ArtifactsFunctions.getGenericArtifact(GetGenericArtifactArgs.builder()
            .artifactId(testArtifact.id())
            .build());
    }
}
variables:
  testGenericArtifact:
    fn::invoke:
      function: oci:Artifacts:getGenericArtifact
      arguments:
        artifactId: ${testArtifact.id}
Using getGenericArtifact
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 getGenericArtifact(args: GetGenericArtifactArgs, opts?: InvokeOptions): Promise<GetGenericArtifactResult>
function getGenericArtifactOutput(args: GetGenericArtifactOutputArgs, opts?: InvokeOptions): Output<GetGenericArtifactResult>def get_generic_artifact(artifact_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetGenericArtifactResult
def get_generic_artifact_output(artifact_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetGenericArtifactResult]func LookupGenericArtifact(ctx *Context, args *LookupGenericArtifactArgs, opts ...InvokeOption) (*LookupGenericArtifactResult, error)
func LookupGenericArtifactOutput(ctx *Context, args *LookupGenericArtifactOutputArgs, opts ...InvokeOption) LookupGenericArtifactResultOutput> Note: This function is named LookupGenericArtifact in the Go SDK.
public static class GetGenericArtifact 
{
    public static Task<GetGenericArtifactResult> InvokeAsync(GetGenericArtifactArgs args, InvokeOptions? opts = null)
    public static Output<GetGenericArtifactResult> Invoke(GetGenericArtifactInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetGenericArtifactResult> getGenericArtifact(GetGenericArtifactArgs args, InvokeOptions options)
public static Output<GetGenericArtifactResult> getGenericArtifact(GetGenericArtifactArgs args, InvokeOptions options)
fn::invoke:
  function: oci:Artifacts/getGenericArtifact:getGenericArtifact
  arguments:
    # arguments dictionaryThe following arguments are supported:
- ArtifactId string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- ArtifactId string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- artifactId String
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- artifactId string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- artifact_id str
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- artifactId String
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
getGenericArtifact Result
The following output properties are available:
- ArtifactId string
- ArtifactPath string
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- CompartmentId string
- The OCID of the repository's compartment.
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DisplayName string
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- Dictionary<string, string>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- RepositoryId string
- The OCID of the repository.
- Sha256 string
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- SizeIn stringBytes 
- The size of the artifact in bytes.
- State string
- The current state of the artifact.
- TimeCreated string
- An RFC 3339 timestamp indicating when the repository was created.
- Version string
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
- ArtifactId string
- ArtifactPath string
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- CompartmentId string
- The OCID of the repository's compartment.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DisplayName string
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- map[string]string
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- RepositoryId string
- The OCID of the repository.
- Sha256 string
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- SizeIn stringBytes 
- The size of the artifact in bytes.
- State string
- The current state of the artifact.
- TimeCreated string
- An RFC 3339 timestamp indicating when the repository was created.
- Version string
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
- artifactId String
- artifactPath String
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- compartmentId String
- The OCID of the repository's compartment.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName String
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- Map<String,String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- repositoryId String
- The OCID of the repository.
- sha256 String
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- sizeIn StringBytes 
- The size of the artifact in bytes.
- state String
- The current state of the artifact.
- timeCreated String
- An RFC 3339 timestamp indicating when the repository was created.
- version String
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
- artifactId string
- artifactPath string
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- compartmentId string
- The OCID of the repository's compartment.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName string
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- {[key: string]: string}
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id string
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- repositoryId string
- The OCID of the repository.
- sha256 string
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- sizeIn stringBytes 
- The size of the artifact in bytes.
- state string
- The current state of the artifact.
- timeCreated string
- An RFC 3339 timestamp indicating when the repository was created.
- version string
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
- artifact_id str
- artifact_path str
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- compartment_id str
- The OCID of the repository's compartment.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- display_name str
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- Mapping[str, str]
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id str
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- repository_id str
- The OCID of the repository.
- sha256 str
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- size_in_ strbytes 
- The size of the artifact in bytes.
- state str
- The current state of the artifact.
- time_created str
- An RFC 3339 timestamp indicating when the repository was created.
- version str
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
- artifactId String
- artifactPath String
- A user-defined path to describe the location of an artifact. Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version. Example: project01/my-web-app/artifact-abc
- compartmentId String
- The OCID of the repository's compartment.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName String
- The artifact name with the format of <artifact-path>:<artifact-version>. The artifact name is truncated to a maximum length of 255. Example:project01/my-web-app/artifact-abc:1.0.0
- Map<String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the artifact. Example: ocid1.genericartifact.oc1..exampleuniqueID
- repositoryId String
- The OCID of the repository.
- sha256 String
- The SHA256 digest for the artifact. When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- sizeIn StringBytes 
- The size of the artifact in bytes.
- state String
- The current state of the artifact.
- timeCreated String
- An RFC 3339 timestamp indicating when the repository was created.
- version String
- A user-defined string to describe the artifact version. Example: 1.1.0or1.2-beta-2
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.