@aws-amplify/api 4.0.33-cloud-logging.9 → 4.0.33-unstable.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aws-amplify-api.js +44 -63
- package/dist/aws-amplify-api.js.map +1 -1
- package/dist/aws-amplify-api.min.js +1 -1
- package/dist/aws-amplify-api.min.js.map +1 -1
- package/lib/API.d.ts +62 -44
- package/lib/API.js +31 -37
- package/lib/API.js.map +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js.map +1 -1
- package/lib/types/index.d.ts +7 -0
- package/lib-esm/API.d.ts +62 -44
- package/lib-esm/API.js +31 -37
- package/lib-esm/API.js.map +1 -1
- package/lib-esm/index.d.ts +1 -0
- package/lib-esm/index.js.map +1 -1
- package/lib-esm/types/index.d.ts +7 -0
- package/package.json +4 -4
- package/src/API.ts +86 -46
- package/src/index.ts +2 -0
- package/src/types/index.ts +8 -0
package/dist/aws-amplify-api.js
CHANGED
|
@@ -9889,9 +9889,9 @@ function () {
|
|
|
9889
9889
|
/**
|
|
9890
9890
|
* Executes a GraphQL operation
|
|
9891
9891
|
*
|
|
9892
|
-
* @param
|
|
9893
|
-
* @param
|
|
9894
|
-
* @returns
|
|
9892
|
+
* @param options - GraphQL Options
|
|
9893
|
+
* @param [additionalHeaders] - headers to merge in after any `graphql_headers` set in the config
|
|
9894
|
+
* @returns An Observable if the query is a subscription query, else a promise of the graphql result.
|
|
9895
9895
|
*/
|
|
9896
9896
|
|
|
9897
9897
|
|
|
@@ -9941,9 +9941,10 @@ function () {
|
|
|
9941
9941
|
variables: variables,
|
|
9942
9942
|
authMode: authMode
|
|
9943
9943
|
}, headers);
|
|
9944
|
-
}
|
|
9945
9944
|
|
|
9946
|
-
|
|
9945
|
+
default:
|
|
9946
|
+
throw new Error("invalid operation type: " + operationType);
|
|
9947
|
+
}
|
|
9947
9948
|
};
|
|
9948
9949
|
|
|
9949
9950
|
GraphQLAPIClass.prototype._graphql = function (_a, additionalHeaders, initParams) {
|
|
@@ -12749,11 +12750,7 @@ function (_super) {
|
|
|
12749
12750
|
};
|
|
12750
12751
|
|
|
12751
12752
|
AWSAppSyncRealTimeProvider.prototype._handleIncomingSubscriptionMessage = function (message) {
|
|
12752
|
-
|
|
12753
|
-
logger.verbose("subscription message from AWS AppSync RealTime: " + message.data);
|
|
12754
|
-
} else {
|
|
12755
|
-
logger.debug("subscription message from AWS AppSync RealTime: " + message.data);
|
|
12756
|
-
}
|
|
12753
|
+
logger.debug("subscription message from AWS AppSync RealTime: " + message.data);
|
|
12757
12754
|
|
|
12758
12755
|
var _a = JSON.parse(message.data),
|
|
12759
12756
|
_b = _a.id,
|
|
@@ -12772,21 +12769,12 @@ function (_super) {
|
|
|
12772
12769
|
subscriptionReadyCallback = _c.subscriptionReadyCallback,
|
|
12773
12770
|
subscriptionFailedCallback = _c.subscriptionFailedCallback;
|
|
12774
12771
|
|
|
12775
|
-
|
|
12776
|
-
|
|
12777
|
-
|
|
12778
|
-
|
|
12779
|
-
|
|
12780
|
-
|
|
12781
|
-
});
|
|
12782
|
-
} else {
|
|
12783
|
-
logger.debug({
|
|
12784
|
-
id: id,
|
|
12785
|
-
observer: observer,
|
|
12786
|
-
query: query,
|
|
12787
|
-
variables: variables
|
|
12788
|
-
});
|
|
12789
|
-
}
|
|
12772
|
+
logger.debug({
|
|
12773
|
+
id: id,
|
|
12774
|
+
observer: observer,
|
|
12775
|
+
query: query,
|
|
12776
|
+
variables: variables
|
|
12777
|
+
});
|
|
12790
12778
|
|
|
12791
12779
|
if (type === MESSAGE_TYPES.GQL_DATA && payload && payload.data) {
|
|
12792
12780
|
if (observer) {
|
|
@@ -15211,10 +15199,10 @@ function () {
|
|
|
15211
15199
|
};
|
|
15212
15200
|
/**
|
|
15213
15201
|
* Make a GET request
|
|
15214
|
-
* @param
|
|
15215
|
-
* @param
|
|
15216
|
-
* @param
|
|
15217
|
-
* @return
|
|
15202
|
+
* @param apiName - The api name of the request
|
|
15203
|
+
* @param path - The path of the request
|
|
15204
|
+
* @param [init] - Request extra params
|
|
15205
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15218
15206
|
*/
|
|
15219
15207
|
|
|
15220
15208
|
|
|
@@ -15223,10 +15211,10 @@ function () {
|
|
|
15223
15211
|
};
|
|
15224
15212
|
/**
|
|
15225
15213
|
* Make a POST request
|
|
15226
|
-
* @param
|
|
15227
|
-
* @param
|
|
15228
|
-
* @param
|
|
15229
|
-
* @return
|
|
15214
|
+
* @param apiName - The api name of the request
|
|
15215
|
+
* @param path - The path of the request
|
|
15216
|
+
* @param [init] - Request extra params
|
|
15217
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15230
15218
|
*/
|
|
15231
15219
|
|
|
15232
15220
|
|
|
@@ -15235,10 +15223,10 @@ function () {
|
|
|
15235
15223
|
};
|
|
15236
15224
|
/**
|
|
15237
15225
|
* Make a PUT request
|
|
15238
|
-
* @param
|
|
15239
|
-
* @param
|
|
15240
|
-
* @param
|
|
15241
|
-
* @return
|
|
15226
|
+
* @param apiName - The api name of the request
|
|
15227
|
+
* @param path - The path of the request
|
|
15228
|
+
* @param [init] - Request extra params
|
|
15229
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15242
15230
|
*/
|
|
15243
15231
|
|
|
15244
15232
|
|
|
@@ -15247,10 +15235,10 @@ function () {
|
|
|
15247
15235
|
};
|
|
15248
15236
|
/**
|
|
15249
15237
|
* Make a PATCH request
|
|
15250
|
-
* @param
|
|
15251
|
-
* @param
|
|
15252
|
-
* @param
|
|
15253
|
-
* @return
|
|
15238
|
+
* @param apiName - The api name of the request
|
|
15239
|
+
* @param path - The path of the request
|
|
15240
|
+
* @param [init] - Request extra params
|
|
15241
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15254
15242
|
*/
|
|
15255
15243
|
|
|
15256
15244
|
|
|
@@ -15259,10 +15247,10 @@ function () {
|
|
|
15259
15247
|
};
|
|
15260
15248
|
/**
|
|
15261
15249
|
* Make a DEL request
|
|
15262
|
-
* @param
|
|
15263
|
-
* @param
|
|
15264
|
-
* @param
|
|
15265
|
-
* @return
|
|
15250
|
+
* @param apiName - The api name of the request
|
|
15251
|
+
* @param path - The path of the request
|
|
15252
|
+
* @param [init] - Request extra params
|
|
15253
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15266
15254
|
*/
|
|
15267
15255
|
|
|
15268
15256
|
|
|
@@ -15271,10 +15259,10 @@ function () {
|
|
|
15271
15259
|
};
|
|
15272
15260
|
/**
|
|
15273
15261
|
* Make a HEAD request
|
|
15274
|
-
* @param
|
|
15275
|
-
* @param
|
|
15276
|
-
* @param
|
|
15277
|
-
* @return
|
|
15262
|
+
* @param apiName - The api name of the request
|
|
15263
|
+
* @param path - The path of the request
|
|
15264
|
+
* @param [init] - Request extra params
|
|
15265
|
+
* @return A promise that resolves to an object with response status and JSON data, if successful.
|
|
15278
15266
|
*/
|
|
15279
15267
|
|
|
15280
15268
|
|
|
@@ -15283,8 +15271,8 @@ function () {
|
|
|
15283
15271
|
};
|
|
15284
15272
|
/**
|
|
15285
15273
|
* Checks to see if an error thrown is from an api request cancellation
|
|
15286
|
-
* @param
|
|
15287
|
-
* @return
|
|
15274
|
+
* @param error - Any error
|
|
15275
|
+
* @return If the error was from an api request cancellation
|
|
15288
15276
|
*/
|
|
15289
15277
|
|
|
15290
15278
|
|
|
@@ -15293,8 +15281,9 @@ function () {
|
|
|
15293
15281
|
};
|
|
15294
15282
|
/**
|
|
15295
15283
|
* Cancels an inflight request
|
|
15296
|
-
* @param
|
|
15297
|
-
* @
|
|
15284
|
+
* @param request - request to cancel
|
|
15285
|
+
* @param [message] - custom error message
|
|
15286
|
+
* @return If the request was cancelled
|
|
15298
15287
|
*/
|
|
15299
15288
|
|
|
15300
15289
|
|
|
@@ -15303,8 +15292,8 @@ function () {
|
|
|
15303
15292
|
};
|
|
15304
15293
|
/**
|
|
15305
15294
|
* Getting endpoint for API
|
|
15306
|
-
* @param
|
|
15307
|
-
* @return
|
|
15295
|
+
* @param apiName - The name of the api
|
|
15296
|
+
* @return The endpoint of the api
|
|
15308
15297
|
*/
|
|
15309
15298
|
|
|
15310
15299
|
|
|
@@ -15326,14 +15315,6 @@ function () {
|
|
|
15326
15315
|
APIClass.prototype.getGraphqlOperationType = function (operation) {
|
|
15327
15316
|
return this._graphqlApi.getGraphqlOperationType(operation);
|
|
15328
15317
|
};
|
|
15329
|
-
/**
|
|
15330
|
-
* Executes a GraphQL operation
|
|
15331
|
-
*
|
|
15332
|
-
* @param {GraphQLOptions} GraphQL Options
|
|
15333
|
-
* @param {object} additionalHeaders headers to merge in after any `graphql_headers` set in the config
|
|
15334
|
-
* @returns {Promise<GraphQLResult> | Observable<object>}
|
|
15335
|
-
*/
|
|
15336
|
-
|
|
15337
15318
|
|
|
15338
15319
|
APIClass.prototype.graphql = function (options, additionalHeaders) {
|
|
15339
15320
|
return this._graphqlApi.graphql(options, additionalHeaders);
|