swagger-api / swagger-api/swagger-codegen

Question about output of swagger-codegen

Open
#9,924 0 comments 0 reactions 1 assignee View on GitHub

@HugoMario is already working on this.

Since May 8, 2020.

Dominant language
Mustache
Stars
17.8k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

Description

I am trying to run

swagger-codegen generate -i http://petstore.swagger.io/v2/swagger.json -l php -o ./petstore

My understanding is that it should build an ApliClient.php file, but I'm not seeing it after running the command. This appears to be the class that is used by the individual API files passed as an optional argument as seen here:

public function __construct(
        ClientInterface $client = null,
        Configuration $config = null,
        HeaderSelector $selector = null
    ) {
        $this->client = $client ?: new Client();
        $this->config = $config ?: new Configuration();
        $this->headerSelector = $selector ?: new HeaderSelector();
    }

Am I just misunderstanding something here or what is the trick to get the ApiClient.php file to be generated?

Swagger-codegen version

3.0.14 (installed via Homebrew)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.