flutter_graphql_client 0.1.24 copy "flutter_graphql_client: ^0.1.24" to clipboard
flutter_graphql_client: ^0.1.24 copied to clipboard

outdated

Client to POST to GraphQL server

example/example.md

/// Making GRAPHQL calls

final dynamic data = await SimpleCall.callAPI(
    querystring: 'valid-query-string' ,
    variables: <String, dynamic>{'pay':'load'},
    graphClient: graphQlClientInstance ,
)

/// Making REST calls

GET

final dynamic data = await SimpleCall.callRestAPI(
    endpoint: 'http://example.com/test' ,
    method: 'GET',
    graphClient: graphQlClientInstance ,
)

POST

final dynamic data = await SimpleCall.callRestAPI(
    endpoint: 'http://example.com/test' ,
    method: 'POST',
    variables: <String, dynamic>{'pay':'load'},
    graphClient: graphQlClientInstance ,
)