Thread overview
A potentially interesting project
Oct 18, 2021
SealabJaster
Oct 19, 2021
James Blachly
Oct 20, 2021
SealabJaster
October 18, 2021

Was recently pondering if it were possible to auto-generate a client for the AWS API.

I decided to see how the official SDKs were made, and found out that Amazon created a tool called Smithy: https://github.com/awslabs/smithy

They've written their more recent SDKs via code generation in Smithy, see for example:

The base Go generator: https://github.com/aws/smithy-go

The generation specifically for the Go SDK: https://github.com/aws/aws-sdk-go-v2/tree/main/codegen

This is too much effort for me to personally bother with (plus I barely know Java), but I thought it might take someone else's interest, especially since I struggled to find any hint of this being a thing in the first place.

October 18, 2021

On Monday, 18 October 2021 at 02:18:36 UTC, SealabJaster wrote:

>

Was recently pondering if it were possible to auto-generate a client for the AWS API.

I decided to see how the official SDKs were made, and found out that Amazon created a tool called Smithy: https://github.com/awslabs/smithy

They've written their more recent SDKs via code generation in Smithy, see for example:

The base Go generator: https://github.com/aws/smithy-go

The generation specifically for the Go SDK: https://github.com/aws/aws-sdk-go-v2/tree/main/codegen

This is too much effort for me to personally bother with (plus I barely know Java), but I thought it might take someone else's interest, especially since I struggled to find any hint of this being a thing in the first place.

Interesting! One of last year's SAoC projects was "D Language Client Libraries for Google APIs" [¹] [²] [³], so given what it was accomplished, I think a "D Client Libraries for AWS (or Microsoft Graph) APIs" project would be a logical next step.

October 18, 2021
On 10/17/21 10:18 PM, SealabJaster wrote:
> Was recently pondering if it were possible to auto-generate a client for the AWS API.
> 
> I decided to see how the official SDKs were made, and found out that Amazon created a tool called Smithy: https://github.com/awslabs/smithy
> 
> They've written their more recent SDKs via code generation in Smithy, see for example:
> 
> The base Go generator: https://github.com/aws/smithy-go
> 
> The generation specifically for the Go SDK: https://github.com/aws/aws-sdk-go-v2/tree/main/codegen
> 
> This is too much effort for me to personally bother with (plus I barely know Java), but I thought it might take someone else's interest, especially since I struggled to find any hint of this being a thing in the first place.

You know, IIRC I saw someone who had prototyped such a thing (for D) when poking around Github late one night. I wish I could think of where I saw it. The repo had the entire JSON file documenting the AWS API surface, and -- I believe -- there was some code that had parsed just the S3 namespace and generated dlang code for this.

In any case, I think this would be a tremendous project, and infinitely more maintainable than one that did NOT automatically generate code ...
October 20, 2021
On Tuesday, 19 October 2021 at 00:08:09 UTC, James Blachly wrote:
> In any case, I think this would be a tremendous project, and infinitely more maintainable than one that did NOT automatically generate code ...

My thoughts exactly.