UNPKG

7.61 kBTypeScriptView Raw
1import {Request} from '../lib/request';
2import {Response} from '../lib/response';
3import {AWSError} from '../lib/error';
4import {Service} from '../lib/service';
5import {ServiceConfigurationOptions} from '../lib/service';
6import {ConfigBase as Config} from '../lib/config';
7interface Blob {}
8declare class CodeStarconnections extends Service {
9 /**
10 * Constructs a service object. This object has one method for each API operation.
11 */
12 constructor(options?: CodeStarconnections.Types.ClientConfiguration)
13 config: Config & CodeStarconnections.Types.ClientConfiguration;
14 /**
15 * Creates a connection that can then be given to other AWS services like CodePipeline so that it can access third-party code repositories. The connection is in pending status until the third-party connection handshake is completed from the console.
16 */
17 createConnection(params: CodeStarconnections.Types.CreateConnectionInput, callback?: (err: AWSError, data: CodeStarconnections.Types.CreateConnectionOutput) => void): Request<CodeStarconnections.Types.CreateConnectionOutput, AWSError>;
18 /**
19 * Creates a connection that can then be given to other AWS services like CodePipeline so that it can access third-party code repositories. The connection is in pending status until the third-party connection handshake is completed from the console.
20 */
21 createConnection(callback?: (err: AWSError, data: CodeStarconnections.Types.CreateConnectionOutput) => void): Request<CodeStarconnections.Types.CreateConnectionOutput, AWSError>;
22 /**
23 * The connection to be deleted.
24 */
25 deleteConnection(params: CodeStarconnections.Types.DeleteConnectionInput, callback?: (err: AWSError, data: CodeStarconnections.Types.DeleteConnectionOutput) => void): Request<CodeStarconnections.Types.DeleteConnectionOutput, AWSError>;
26 /**
27 * The connection to be deleted.
28 */
29 deleteConnection(callback?: (err: AWSError, data: CodeStarconnections.Types.DeleteConnectionOutput) => void): Request<CodeStarconnections.Types.DeleteConnectionOutput, AWSError>;
30 /**
31 * Returns the connection ARN and details such as status, owner, and provider type.
32 */
33 getConnection(params: CodeStarconnections.Types.GetConnectionInput, callback?: (err: AWSError, data: CodeStarconnections.Types.GetConnectionOutput) => void): Request<CodeStarconnections.Types.GetConnectionOutput, AWSError>;
34 /**
35 * Returns the connection ARN and details such as status, owner, and provider type.
36 */
37 getConnection(callback?: (err: AWSError, data: CodeStarconnections.Types.GetConnectionOutput) => void): Request<CodeStarconnections.Types.GetConnectionOutput, AWSError>;
38 /**
39 * Lists the connections associated with your account.
40 */
41 listConnections(params: CodeStarconnections.Types.ListConnectionsInput, callback?: (err: AWSError, data: CodeStarconnections.Types.ListConnectionsOutput) => void): Request<CodeStarconnections.Types.ListConnectionsOutput, AWSError>;
42 /**
43 * Lists the connections associated with your account.
44 */
45 listConnections(callback?: (err: AWSError, data: CodeStarconnections.Types.ListConnectionsOutput) => void): Request<CodeStarconnections.Types.ListConnectionsOutput, AWSError>;
46}
47declare namespace CodeStarconnections {
48 export type AccountId = string;
49 export interface Connection {
50 /**
51 * The name of the connection. Connection names must be unique in an AWS user account.
52 */
53 ConnectionName?: ConnectionName;
54 /**
55 * The Amazon Resource Name (ARN) of the connection. The ARN is used as the connection reference when the connection is shared between AWS services. The ARN is never reused if the connection is deleted.
56 */
57 ConnectionArn?: ConnectionArn;
58 /**
59 * The name of the external provider where your third-party code repository is configured. Currently, the valid provider type is Bitbucket.
60 */
61 ProviderType?: ProviderType;
62 /**
63 * The name of the external provider where your third-party code repository is configured. For Bitbucket, this is the account ID of the owner of the Bitbucket repository.
64 */
65 OwnerAccountId?: AccountId;
66 /**
67 * The current status of the connection.
68 */
69 ConnectionStatus?: ConnectionStatus;
70 }
71 export type ConnectionArn = string;
72 export type ConnectionList = Connection[];
73 export type ConnectionName = string;
74 export type ConnectionStatus = "PENDING"|"AVAILABLE"|"ERROR"|string;
75 export interface CreateConnectionInput {
76 /**
77 * The name of the external provider where your third-party code repository is configured. Currently, the valid provider type is Bitbucket.
78 */
79 ProviderType: ProviderType;
80 /**
81 * The name of the connection to be created. The name must be unique in the calling AWS account.
82 */
83 ConnectionName: ConnectionName;
84 }
85 export interface CreateConnectionOutput {
86 /**
87 * The Amazon Resource Name (ARN) of the connection to be created. The ARN is used as the connection reference when the connection is shared between AWS services. The ARN is never reused if the connection is deleted.
88 */
89 ConnectionArn: ConnectionArn;
90 }
91 export interface DeleteConnectionInput {
92 /**
93 * The Amazon Resource Name (ARN) of the connection to be deleted. The ARN is never reused if the connection is deleted.
94 */
95 ConnectionArn: ConnectionArn;
96 }
97 export interface DeleteConnectionOutput {
98 }
99 export interface GetConnectionInput {
100 /**
101 * The Amazon Resource Name (ARN) of a connection.
102 */
103 ConnectionArn: ConnectionArn;
104 }
105 export interface GetConnectionOutput {
106 /**
107 * The connection details, such as status, owner, and provider type.
108 */
109 Connection?: Connection;
110 }
111 export interface ListConnectionsInput {
112 /**
113 * Filters the list of connections to those associated with a specified provider, such as Bitbucket.
114 */
115 ProviderTypeFilter?: ProviderType;
116 /**
117 * The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned nextToken value.
118 */
119 MaxResults?: MaxResults;
120 /**
121 * The token that was returned from the previous ListConnections call, which can be used to return the next set of connections in the list.
122 */
123 NextToken?: NextToken;
124 }
125 export interface ListConnectionsOutput {
126 /**
127 * A list of connections and the details for each connection, such as status, owner, and provider type.
128 */
129 Connections?: ConnectionList;
130 /**
131 * A token that can be used in the next ListConnections call. To view all items in the list, continue to call this operation with each subsequent token until no more nextToken values are returned.
132 */
133 NextToken?: NextToken;
134 }
135 export type MaxResults = number;
136 export type NextToken = string;
137 export type ProviderType = "Bitbucket"|string;
138 /**
139 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
140 */
141 export type apiVersion = "2019-12-01"|"latest"|string;
142 export interface ClientApiVersions {
143 /**
144 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
145 */
146 apiVersion?: apiVersion;
147 }
148 export type ClientConfiguration = ServiceConfigurationOptions & ClientApiVersions;
149 /**
150 * Contains interfaces for use with the CodeStarconnections client.
151 */
152 export import Types = CodeStarconnections;
153}
154export = CodeStarconnections;