moko-network icon indicating copy to clipboard operation
moko-network copied to clipboard

Support at generator of request parameters with Nullable type

Open Tetraquark opened this issue 4 years ago • 0 comments

Need to add support to the network-generator of nullable parameters of a request.

In spec:

paths:
  /users:
    get:
      parameters:
        - name: "client_id"
          in: "query"
          schema:
            type: string
            nullable: true
          required: true
      summary: Returns a list of users.
      description: Optional extended description in CommonMark or HTML.

Generator should create code like this:

override public open suspend fun users(client_id: dev.icerock.moko.network.nullable.Nullable<kotlin.String>) : Unit

Tetraquark avatar Aug 19 '21 09:08 Tetraquark