Skip to content

Commit

Permalink
Update swan-lake/resources/featured-scenarios/write-a-graphql-api-wit…
Browse files Browse the repository at this point in the history
…h-ballerina.md

Co-authored-by: Thisaru Guruge <thisaru@wso2.com>
  • Loading branch information
praneesha and ThisaruGuruge committed Feb 27, 2024
1 parent 058e274 commit 27a48ab
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Before writing the GraphQL service, let's create a data source for the project.

Follow the steps below to add the definitions of the data types and the declaration of the table.

1. Generate the record types corresponding to the payload from the REST service by providing the record name as `CovidEntry` and the sample JSON object below.
1. Generate the record type corresponding to the table entry providing the record name as `CovidEntry` and the sample JSON object below.

>**Tip:** You need to complete the generated record by adding the pipe signs to mark the record as a closed one, adding the `readonly` descriptor to the `isoCode` field to make it non-modifiable as it is the key of the table, and marking the values of the `cases`, `deaths`, `recovered`, and `active` variables as optional, which cannot be represented in the JSON format.
Expand Down

0 comments on commit 27a48ab

Please sign in to comment.