1. Packages
  2. AWS
  3. API Docs
  4. appsync
  5. SourceApiAssociation
AWS v6.77.0 published on Wednesday, Apr 9, 2025 by Pulumi

aws.appsync.SourceApiAssociation

Explore with Pulumi AI

Resource for managing an AWS AppSync Source Api Association.

Example Usage

Basic Usage

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

const test = new aws.appsync.SourceApiAssociation("test", {
    description: "My source API Merged",
    mergedApiId: "gzos6bteufdunffzzifiowisoe",
    sourceApiId: "fzzifiowisoegzos6bteufdunf",
});
Copy
import pulumi
import pulumi_aws as aws

test = aws.appsync.SourceApiAssociation("test",
    description="My source API Merged",
    merged_api_id="gzos6bteufdunffzzifiowisoe",
    source_api_id="fzzifiowisoegzos6bteufdunf")
Copy
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/appsync"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := appsync.NewSourceApiAssociation(ctx, "test", &appsync.SourceApiAssociationArgs{
			Description: pulumi.String("My source API Merged"),
			MergedApiId: pulumi.String("gzos6bteufdunffzzifiowisoe"),
			SourceApiId: pulumi.String("fzzifiowisoegzos6bteufdunf"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var test = new Aws.AppSync.SourceApiAssociation("test", new()
    {
        Description = "My source API Merged",
        MergedApiId = "gzos6bteufdunffzzifiowisoe",
        SourceApiId = "fzzifiowisoegzos6bteufdunf",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.appsync.SourceApiAssociation;
import com.pulumi.aws.appsync.SourceApiAssociationArgs;
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) {
        var test = new SourceApiAssociation("test", SourceApiAssociationArgs.builder()
            .description("My source API Merged")
            .mergedApiId("gzos6bteufdunffzzifiowisoe")
            .sourceApiId("fzzifiowisoegzos6bteufdunf")
            .build());

    }
}
Copy
resources:
  test:
    type: aws:appsync:SourceApiAssociation
    properties:
      description: My source API Merged
      mergedApiId: gzos6bteufdunffzzifiowisoe
      sourceApiId: fzzifiowisoegzos6bteufdunf
Copy

Create SourceApiAssociation Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new SourceApiAssociation(name: string, args?: SourceApiAssociationArgs, opts?: CustomResourceOptions);
@overload
def SourceApiAssociation(resource_name: str,
                         args: Optional[SourceApiAssociationArgs] = None,
                         opts: Optional[ResourceOptions] = None)

@overload
def SourceApiAssociation(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         description: Optional[str] = None,
                         merged_api_arn: Optional[str] = None,
                         merged_api_id: Optional[str] = None,
                         source_api_arn: Optional[str] = None,
                         source_api_association_configs: Optional[Sequence[SourceApiAssociationSourceApiAssociationConfigArgs]] = None,
                         source_api_id: Optional[str] = None,
                         timeouts: Optional[SourceApiAssociationTimeoutsArgs] = None)
func NewSourceApiAssociation(ctx *Context, name string, args *SourceApiAssociationArgs, opts ...ResourceOption) (*SourceApiAssociation, error)
public SourceApiAssociation(string name, SourceApiAssociationArgs? args = null, CustomResourceOptions? opts = null)
public SourceApiAssociation(String name, SourceApiAssociationArgs args)
public SourceApiAssociation(String name, SourceApiAssociationArgs args, CustomResourceOptions options)
type: aws:appsync:SourceApiAssociation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args SourceApiAssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args SourceApiAssociationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args SourceApiAssociationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args SourceApiAssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. SourceApiAssociationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var sourceApiAssociationResource = new Aws.AppSync.SourceApiAssociation("sourceApiAssociationResource", new()
{
    Description = "string",
    MergedApiArn = "string",
    MergedApiId = "string",
    SourceApiArn = "string",
    SourceApiAssociationConfigs = new[]
    {
        new Aws.AppSync.Inputs.SourceApiAssociationSourceApiAssociationConfigArgs
        {
            MergeType = "string",
        },
    },
    SourceApiId = "string",
    Timeouts = new Aws.AppSync.Inputs.SourceApiAssociationTimeoutsArgs
    {
        Create = "string",
        Delete = "string",
        Update = "string",
    },
});
Copy
example, err := appsync.NewSourceApiAssociation(ctx, "sourceApiAssociationResource", &appsync.SourceApiAssociationArgs{
	Description:  pulumi.String("string"),
	MergedApiArn: pulumi.String("string"),
	MergedApiId:  pulumi.String("string"),
	SourceApiArn: pulumi.String("string"),
	SourceApiAssociationConfigs: appsync.SourceApiAssociationSourceApiAssociationConfigArray{
		&appsync.SourceApiAssociationSourceApiAssociationConfigArgs{
			MergeType: pulumi.String("string"),
		},
	},
	SourceApiId: pulumi.String("string"),
	Timeouts: &appsync.SourceApiAssociationTimeoutsArgs{
		Create: pulumi.String("string"),
		Delete: pulumi.String("string"),
		Update: pulumi.String("string"),
	},
})
Copy
var sourceApiAssociationResource = new SourceApiAssociation("sourceApiAssociationResource", SourceApiAssociationArgs.builder()
    .description("string")
    .mergedApiArn("string")
    .mergedApiId("string")
    .sourceApiArn("string")
    .sourceApiAssociationConfigs(SourceApiAssociationSourceApiAssociationConfigArgs.builder()
        .mergeType("string")
        .build())
    .sourceApiId("string")
    .timeouts(SourceApiAssociationTimeoutsArgs.builder()
        .create("string")
        .delete("string")
        .update("string")
        .build())
    .build());
Copy
source_api_association_resource = aws.appsync.SourceApiAssociation("sourceApiAssociationResource",
    description="string",
    merged_api_arn="string",
    merged_api_id="string",
    source_api_arn="string",
    source_api_association_configs=[{
        "merge_type": "string",
    }],
    source_api_id="string",
    timeouts={
        "create": "string",
        "delete": "string",
        "update": "string",
    })
Copy
const sourceApiAssociationResource = new aws.appsync.SourceApiAssociation("sourceApiAssociationResource", {
    description: "string",
    mergedApiArn: "string",
    mergedApiId: "string",
    sourceApiArn: "string",
    sourceApiAssociationConfigs: [{
        mergeType: "string",
    }],
    sourceApiId: "string",
    timeouts: {
        create: "string",
        "delete": "string",
        update: "string",
    },
});
Copy
type: aws:appsync:SourceApiAssociation
properties:
    description: string
    mergedApiArn: string
    mergedApiId: string
    sourceApiArn: string
    sourceApiAssociationConfigs:
        - mergeType: string
    sourceApiId: string
    timeouts:
        create: string
        delete: string
        update: string
Copy

SourceApiAssociation Resource Properties

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

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The SourceApiAssociation resource accepts the following input properties:

Description string
Description of the source API being merged.
MergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
MergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
SourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
SourceApiAssociationConfigs List<SourceApiAssociationSourceApiAssociationConfig>
SourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
Timeouts SourceApiAssociationTimeouts
Description string
Description of the source API being merged.
MergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
MergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
SourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
SourceApiAssociationConfigs []SourceApiAssociationSourceApiAssociationConfigArgs
SourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
Timeouts SourceApiAssociationTimeoutsArgs
description String
Description of the source API being merged.
mergedApiArn String
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId String
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn String
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs List<SourceApiAssociationSourceApiAssociationConfig>
sourceApiId String
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeouts
description string
Description of the source API being merged.
mergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs SourceApiAssociationSourceApiAssociationConfig[]
sourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeouts
description str
Description of the source API being merged.
merged_api_arn str
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
merged_api_id str
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
source_api_arn str
ARN of the source API. One of source_api_arn or source_api_id must be specified.
source_api_association_configs Sequence[SourceApiAssociationSourceApiAssociationConfigArgs]
source_api_id str
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeoutsArgs
description String
Description of the source API being merged.
mergedApiArn String
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId String
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn String
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs List<Property Map>
sourceApiId String
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts Property Map

Outputs

All input properties are implicitly available as output properties. Additionally, the SourceApiAssociation resource produces the following output properties:

Arn string
ARN of the Source Api Association.
AssociationId string
ID of the Source Api Association.
Id string
The provider-assigned unique ID for this managed resource.
Arn string
ARN of the Source Api Association.
AssociationId string
ID of the Source Api Association.
Id string
The provider-assigned unique ID for this managed resource.
arn String
ARN of the Source Api Association.
associationId String
ID of the Source Api Association.
id String
The provider-assigned unique ID for this managed resource.
arn string
ARN of the Source Api Association.
associationId string
ID of the Source Api Association.
id string
The provider-assigned unique ID for this managed resource.
arn str
ARN of the Source Api Association.
association_id str
ID of the Source Api Association.
id str
The provider-assigned unique ID for this managed resource.
arn String
ARN of the Source Api Association.
associationId String
ID of the Source Api Association.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing SourceApiAssociation Resource

Get an existing SourceApiAssociation 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?: SourceApiAssociationState, opts?: CustomResourceOptions): SourceApiAssociation
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        arn: Optional[str] = None,
        association_id: Optional[str] = None,
        description: Optional[str] = None,
        merged_api_arn: Optional[str] = None,
        merged_api_id: Optional[str] = None,
        source_api_arn: Optional[str] = None,
        source_api_association_configs: Optional[Sequence[SourceApiAssociationSourceApiAssociationConfigArgs]] = None,
        source_api_id: Optional[str] = None,
        timeouts: Optional[SourceApiAssociationTimeoutsArgs] = None) -> SourceApiAssociation
func GetSourceApiAssociation(ctx *Context, name string, id IDInput, state *SourceApiAssociationState, opts ...ResourceOption) (*SourceApiAssociation, error)
public static SourceApiAssociation Get(string name, Input<string> id, SourceApiAssociationState? state, CustomResourceOptions? opts = null)
public static SourceApiAssociation get(String name, Output<String> id, SourceApiAssociationState state, CustomResourceOptions options)
resources:  _:    type: aws:appsync:SourceApiAssociation    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
Arn string
ARN of the Source Api Association.
AssociationId string
ID of the Source Api Association.
Description string
Description of the source API being merged.
MergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
MergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
SourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
SourceApiAssociationConfigs List<SourceApiAssociationSourceApiAssociationConfig>
SourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
Timeouts SourceApiAssociationTimeouts
Arn string
ARN of the Source Api Association.
AssociationId string
ID of the Source Api Association.
Description string
Description of the source API being merged.
MergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
MergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
SourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
SourceApiAssociationConfigs []SourceApiAssociationSourceApiAssociationConfigArgs
SourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
Timeouts SourceApiAssociationTimeoutsArgs
arn String
ARN of the Source Api Association.
associationId String
ID of the Source Api Association.
description String
Description of the source API being merged.
mergedApiArn String
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId String
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn String
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs List<SourceApiAssociationSourceApiAssociationConfig>
sourceApiId String
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeouts
arn string
ARN of the Source Api Association.
associationId string
ID of the Source Api Association.
description string
Description of the source API being merged.
mergedApiArn string
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId string
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn string
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs SourceApiAssociationSourceApiAssociationConfig[]
sourceApiId string
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeouts
arn str
ARN of the Source Api Association.
association_id str
ID of the Source Api Association.
description str
Description of the source API being merged.
merged_api_arn str
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
merged_api_id str
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
source_api_arn str
ARN of the source API. One of source_api_arn or source_api_id must be specified.
source_api_association_configs Sequence[SourceApiAssociationSourceApiAssociationConfigArgs]
source_api_id str
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts SourceApiAssociationTimeoutsArgs
arn String
ARN of the Source Api Association.
associationId String
ID of the Source Api Association.
description String
Description of the source API being merged.
mergedApiArn String
ARN of the merged API. One of merged_api_arn or merged_api_id must be specified.
mergedApiId String
ID of the merged API. One of merged_api_arn or merged_api_id must be specified.
sourceApiArn String
ARN of the source API. One of source_api_arn or source_api_id must be specified.
sourceApiAssociationConfigs List<Property Map>
sourceApiId String
ID of the source API. One of source_api_arn or source_api_id must be specified.
timeouts Property Map

Supporting Types

SourceApiAssociationSourceApiAssociationConfig
, SourceApiAssociationSourceApiAssociationConfigArgs

MergeType This property is required. string
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE
MergeType This property is required. string
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE
mergeType This property is required. String
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE
mergeType This property is required. string
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE
merge_type This property is required. str
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE
mergeType This property is required. String
Merge type. Valid values: MANUAL_MERGE, AUTO_MERGE

SourceApiAssociationTimeouts
, SourceApiAssociationTimeoutsArgs

Create string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
Delete string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
Update string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
Create string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
Delete string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
Update string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
create String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
delete String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
update String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
create string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
delete string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
update string
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
create str
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
delete str
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
update str
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
create String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
delete String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours). Setting a timeout for a Delete operation is only applicable if changes are saved into state before the destroy operation occurs.
update String
A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).

Import

Using pulumi import, import AppSync Source Api Association using the gzos6bteufdunffzzifiowisoe,243685a0-9347-4a1a-89c1-9b57dea01e31. For example:

$ pulumi import aws:appsync/sourceApiAssociation:SourceApiAssociation example gzos6bteufdunffzzifiowisoe,243685a0-9347-4a1a-89c1-9b57dea01e31
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
AWS Classic pulumi/pulumi-aws
License
Apache-2.0
Notes
This Pulumi package is based on the aws Terraform Provider.