Prerequisites
Before installing go-siat, ensure you have:Go 1.26 or higher
Install via go get
Install the latest version of go-siat using Go’s package manager:- Download the go-siat SDK
- Add it to your
go.modfile - Download all required dependencies
Verify Installation
Create a simple test file to verify the installation:test.go
Package Structure
Once installed, you’ll have access to these key packages:Environment Configuration
Testing Environment
For development and testing, use the pilot SIAT URL:Production Environment
For production, use your production SIAT URL:Custom HTTP Client
You can provide a custom HTTP client with specific timeout and transport settings:If no HTTP client is provided, go-siat uses a default client with a 15-second timeout.
Additional Dependencies for Invoice Signing
If you plan to sign invoices (required forCompraVenta operations), you’ll need:
- Digital certificate (
.crtfile) issued by a Bolivian certification authority - Private key (
.pemfile) corresponding to your certificate
SignXML utility:
Troubleshooting
Module download errors
Module download errors
If you encounter module download issues:
Version conflicts
Version conflicts
Ensure your
go.mod specifies Go 1.26+:go.mod
Import errors
Import errors
After installation, update dependencies:
Next Steps
Quickstart Guide
Learn how to make your first SIAT API call with a complete working example
