The JAGW-Go repository contains a Go client library for interacting with the Jalapeno API Gateway
Go reference is available at https://pkg.go.dev/github.com/jalapeno-api-gateway/jagw-go. More documentation can be found under https://jalapeno-api-gateway.github.io/jagw. The mock files are generated with https://github.com/uber-go/mock.
Here is a list of code examples with short description of demonstrated JAGW-Go functionality:
- request-all-nodes - request all lsnodes from the gateway
All code examples can be found under examples directory.
Below are short code samples showing a JAGW-Go client interacting with the Jalapeno API Gateway.
// Define the endpoint request/subscription
endpoint := jagw.JagwEndpoint{
EndpointAddress: "localhost",
EndpointPort: 9902,
}
// Get a connection
connection, err := jagw.NewJagwConnection(endpoint)
if err != nil {
panic(err)
}
defer connection.Close()
// Create a new request client
client := jagw.NewRequestServiceClient(connection)
Complete example in request_all_nodes.go
- Contribute code by submitting a Pull Request.
- Report bugs by opening an Issue.
- Ask questions & open discussions by starting a Discussion.