GithubHelp home page GithubHelp logo

Comments (6)

aknuds1 avatar aknuds1 commented on August 11, 2024 2

Does anyone here have examples of usage of generated API client code? I'm trying to use it now, but not sure how to configure the address of the API server.

from smithy-go.

awlsring avatar awlsring commented on August 11, 2024 2

Does anyone here have examples of usage of generated API client code? I'm trying to use it now, but not sure how to configure the address of the API server.

I'm glad its not just me I thought I was going crazy. Any sort of real basic quick start would be super helpful.

from smithy-go.

jabalsad avatar jabalsad commented on August 11, 2024 1

I've since figured out a few basics: you can build and install the plugin yourself by:

make smithy-publish-local

This should create a package located at:
"$HOME/.m2/repository/software/amazon/smithy/go/smithy-go-codegen/0.1.0/smithy-go-codegen-0.1.0.pom

You then need to configure smith-build.json to output go:

    "go-codegen": {
      "service": "my.service#MyService",
      "module": "github.com/my/module"
    },

Lastly you need to add a dependency in the build.gradle.kts:

dependencies {
   ...
    implementation("software.amazon.smithy.go:smithy-go-codegen:0.1.0")
}

I also added it as a buildscript dependency though I'm not really sure how gradle works or what i'm doing.

from smithy-go.

aknuds1 avatar aknuds1 commented on August 11, 2024

I'm in the same boat!

from smithy-go.

FuzzyStatic avatar FuzzyStatic commented on August 11, 2024

You then need to configure smith-build.json to output go:

    "go-codegen": {
      "service": "my.service#MyService",
      "module": "github.com/my/module"
    },

I'd like to note that this should be nested under plugins:

"plugins": {
    "go-codegen": {
       "service": "my.service#MyService",
       "module": "github.com/my/module"
    }
}

from smithy-go.

lucix-aws avatar lucix-aws commented on August 11, 2024

On its own smithy-go isn't usable its in current state - we need to at the very least move the protocol generators out of the SDK into this project (#458). I've updated the README to reflect this.

from smithy-go.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.