Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • O openapi-generator
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 3,476
    • Issues 3,476
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 402
    • Merge requests 402
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • OpenAPI Tools
  • openapi-generator
  • Issues
  • #8606
Closed
Open
Issue created Feb 03, 2021 by Administrator@rootContributor

[BUG] [scala-akka-client] Scala Akka client does not support arbitrary query string values

Created by: ameenhaq

Description

When generating an api with an endpoint that takes an arbitrary set of query string parameters, which is to be represented as Map[String, Any] in the client, the generated code tries to use a query parameter append method that does not support the Map[String, Any] data type.

openapi-generator version

Latest

OpenAPI declaration file content or url
  /api/v1/query:
    get:
      summary: Get a result using some filters
      operationId: getQuery
      parameters:
        - name: filter
          in: query
          required: false
          schema:
            type: object
            additionalProperties: true
Suggest a fix

Currently, it utilises a method withQueryParam which cannot handle a Map type.

def withQueryParam(name: String, value: Any): ApiRequest[U] = copy[U](queryParams = queryParams + (name -> value))

This can be supported by the inclusion of;

def withQueryParam(values: Map[String, Any]): ApiRequest[U] = copy[U](queryParams = queryParams ++ values)

A full solution has been raised as PR #8610.

Assignee
Assign to
Time tracking