APICategory class
Methods
addPlugin (APIPluginInterface plugin , {required AmplifyAuthProviderRepository authProviderRepo })
→ Future <void >
Adds a plugin to the category.
inherited
delete (String path , {HttpPayload ? body , Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP DELETE request to the REST API endpoint.
get (String path , {Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP GET request to the REST API endpoint.
head (String path , {Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP HEAD request to the REST API endpoint.
mutate <T > ({required GraphQLRequest <T > request })
→ GraphQLOperation <T >
Sends a GraphQL mutate request and returns the response in a cancelable GraphQLOperation
.
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
patch (String path , {HttpPayload ? body , Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP PATCH request to the REST API endpoint.
post (String path , {HttpPayload ? body , Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP POST request to the REST API endpoint.
put (String path , {HttpPayload ? body , Map <String , String > ? queryParameters , String ? apiName })
→ RestOperation
Sends an HTTP PUT request to the REST API endpoint.
query <T > ({required GraphQLRequest <T > request })
→ GraphQLOperation <T >
Sends a GraphQL query request and returns the response in a cancelable GraphQLOperation
.
reset ()
→ Future <void >
Resets the category, clearing all registered plugins.
inherited
subscribe <T > (GraphQLRequest <T > request , {void onEstablished ()? })
→ Stream <GraphQLResponse <T > >
Subscribes to the given request
and returns the stream of response events.
An optional onEstablished
callback can be used to be alerted when the
subscription has been successfully established with the server.
toString ()
→ String
A string representation of this object.
inherited