mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-01-16 23:26:52 +01:00
Updated Request Matching GraphQLMatcher (markdown)
@@ -1,7 +1,8 @@
|
||||
## GraphQL Schema (GraphQLMatcher)
|
||||
Can be used to match a GraphQL Query or Mutation using GraphQAL Schema.
|
||||
# GraphQL Schema (GraphQLMatcher)
|
||||
Can be used to match a GraphQL `Query` using GraphQL Schema (`MUtation` is not yet supported I think...)
|
||||
|
||||
#### C# option
|
||||
## Define a mapping which includes a GraphQL Schema which should be used for matching the body:
|
||||
### C#
|
||||
```csharp
|
||||
var TestSchema = @"
|
||||
input MessageInput {
|
||||
@@ -45,7 +46,7 @@ server
|
||||
);
|
||||
```
|
||||
|
||||
#### JSON Mapping option
|
||||
### JSON Mapping
|
||||
``` json
|
||||
{
|
||||
"Guid": "5a36d1c1-11df-4976-90f9-22cae5dadb38",
|
||||
@@ -71,4 +72,7 @@ server
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
```
|
||||
|
||||
## Use / Test
|
||||
When WireMock.Net is started (see above) with that GraphQL Schema, a client can send GraphQL
|
||||
Reference in New Issue
Block a user