An open API service indexing awesome lists of open source software.

https://github.com/syniol/xyo-sdk-go

XYO Financial SDK for Go (Golang)
https://github.com/syniol/xyo-sdk-go

Last synced: 9 months ago
JSON representation

XYO Financial SDK for Go (Golang)

Awesome Lists containing this project

README

          

# XYO Financial SDK Go (Golang)
![workflow](https://github.com/syniol/xyo-sdk-go/actions/workflows/makefile.yml/badge.svg)


Go (Golang) Gopher Mascot

Official Gopher Mascot for XYO.Financial Generated by Adobe AI and Imagined by Syniol Limited

This SDK is official XYO.Financial and maintained by [Syniol Limited](https://syniol.com) for Go (Golang) Programming Language.
The minimum requirement is version: `1.18`. It can be utilised for Trial and Premium accounts, given that a valid API key is
available to connect to and access the Enrichment services.

## Quickstart Guide
First you need to install the XYO SDK for Go (Golang) ecosystem via [GitHub](https://github.com/syniol/xyo-sdk-go).

```shell
go get github.com/syniol/xyo-sdk-go
```

Client is an entry point to use the SDK. You need a valid API Key obtainable from https://xyo.financial/dashboard

```go
package main

import (
"encoding/json"
"log"
"fmt"

"github.com/syniol/xyo-sdk-go"
)

func main() {
client := xyo.NewClient(&xyo.ClientConfig{
APIKey: "YourAPIKeyFromXYO.FinancialDashboard",
})
}
```

__Enrich a Single Payment Transaction__:
```go
package main

import (
"log"
"fmt"

"github.com/syniol/xyo-sdk-go"
)

func main() {
resp, err := client.EnrichTransaction(&xyo.EnrichmentRequest{
Content: "COSTA PICKUP",
CountryCode: "GB",
})
log.Fatal(err)

fmt.Println(resp.Merchant)
fmt.Println(resp.Description)
fmt.Println(resp.Categories)
fmt.Println(resp.Logo)
}
```

__Enrich Payment Transaction Collection _(Bulk Enrichment)___:
```go
package main

import (
"log"
"fmt"

"github.com/syniol/xyo-sdk-go"
)

func main() {
resp, err := client.EnrichTransactionCollection([]*xyo.EnrichmentRequest{
{
Content: 'Costa PickUp',
CountryCode: 'GB',
},
{
Content: 'STRBUKS GREENWICH',
CountryCode: 'GB',
},
})
log.Fatal(err)

fmt.Println(resp.ID)
fmt.Println(resp.Link)
}
```

__Payment Transaction Collection Status__:
```go
package main

import (
"log"
"fmt"
)

func main() {
resp, err := client.EnrichTransactionCollectionStatus(enrichTransactionCollectionResponse.ID)
log.Fatal(err)

// EnrichmentCollectionStatus enum: READY, PENDING, FAILED
fmt.Println(resp)
}
```

#### Credits
Copyright © 2025 Syniol Limited. All rights reserved.