{"id":46069852,"url":"https://github.com/kintsdev/aurora-go-sdk","last_synced_at":"2026-04-25T22:01:22.346Z","repository":{"id":341370570,"uuid":"1169878690","full_name":"kintsdev/aurora-go-sdk","owner":"kintsdev","description":null,"archived":false,"fork":false,"pushed_at":"2026-03-01T11:37:08.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-01T14:52:25.947Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kintsdev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-01T11:13:43.000Z","updated_at":"2026-03-01T11:31:23.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/kintsdev/aurora-go-sdk","commit_stats":null,"previous_names":["kintsdev/aurora-go-sdk"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/kintsdev/aurora-go-sdk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kintsdev%2Faurora-go-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kintsdev%2Faurora-go-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kintsdev%2Faurora-go-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kintsdev%2Faurora-go-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kintsdev","download_url":"https://codeload.github.com/kintsdev/aurora-go-sdk/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kintsdev%2Faurora-go-sdk/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32278249,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-25T18:29:39.964Z","status":"ssl_error","status_checked_at":"2026-04-25T18:29:32.149Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-03-01T13:06:50.718Z","updated_at":"2026-04-25T22:01:22.328Z","avatar_url":"https://github.com/kintsdev.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Aurora Go SDK\n\nOfficial Go SDK for the [Aurora API](https://kints.dev) — a rule-based transaction processing engine.\n\n## Installation\n\n```bash\ngo get github.com/kintsdev/aurora-go-sdk\n```\n\n## Quick Start\n\n```go\npackage main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\t\"log\"\n\n\taurora \"github.com/kintsdev/aurora-go-sdk\"\n)\n\nfunc main() {\n\tclient := aurora.NewClient(\"your-api-key\",\n\t\taurora.WithBaseURL(\"https://api.example.com\"),\n\t)\n\n\tresp, err := client.Process.Execute(context.Background(), \u0026aurora.ProcessRequest{\n\t\tRuleID: \"your-rule-id\",\n\t\tTransaction: \u0026aurora.Transaction{\n\t\t\tCommon: \u0026aurora.Common{\n\t\t\t\tAmount:   250.00,\n\t\t\t\tCurrency: \"USD\",\n\t\t\t\tEmail:    \"customer@example.com\",\n\t\t\t},\n\t\t},\n\t})\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tfmt.Printf(\"Allowed: %v | Rejected: %v | Score: %d\\n\", resp.Allow, resp.Rejected, resp.Score)\n}\n```\n\n## Configuration\n\n### Client Options\n\n| Option | Description |\n|---|---|\n| `WithBaseURL(url)` | Set the API host (e.g. `https://api.example.com`). The path `/api/v1` is appended automatically. |\n| `WithHTTPClient(client)` | Provide a custom `*http.Client`. |\n| `WithTimeout(duration)` | Set HTTP client timeout (default: 30s). |\n\n### Authentication\n\nThe SDK sends the API key as a `Bearer` token in the `Authorization` header.\n\n```go\nclient := aurora.NewClient(\"your-api-key\")\n```\n\n## Process\n\nExecute a rule against a transaction using `client.Process.Execute()`.\n\n### With a Single Rule\n\n```go\nresp, err := client.Process.Execute(ctx, \u0026aurora.ProcessRequest{\n    RuleID: \"rule-id\",\n    Transaction: \u0026aurora.Transaction{\n        Common: \u0026aurora.Common{\n            Amount:   100.00,\n            Currency: \"TRY\",\n            UserID:   \"user-123\",\n        },\n    },\n})\n```\n\n### With a Ruleset\n\n```go\nresp, err := client.Process.Execute(ctx, \u0026aurora.ProcessRequest{\n    RulesetID: \"ruleset-id\",\n    Transaction: \u0026aurora.Transaction{\n        Common: \u0026aurora.Common{\n            Amount:   500.00,\n            Currency: \"EUR\",\n        },\n        Transfer: \u0026aurora.Transfer{\n            PaymentMethod: \"bank_deposit\",\n            SenderCountry: \"DE\",\n        },\n    },\n})\n```\n\n### Full Example\n\n```go\nresp, err := client.Process.Execute(ctx, \u0026aurora.ProcessRequest{\n    RuleID:        \"1e7b3b7b-0b3b-4b7b-8b3b-0b3b7b0b3b7b\",\n    RulesetID:     \"2a8c4d9e-1f2a-4b3c-9d8e-7f6a5b4c3d2e\",\n    TransactionID: \"txn_20260326_0001\",\n    Transaction: \u0026aurora.Transaction{\n        Type:            \"card\",\n        TransactionType: \"purchase\",\n        AccountAgeDays:  \"180\",\n        IsNewDevice:     \"true\",\n        IsNewIP:         \"false\",\n        IsUnusualLocation: \"true\",\n        Common: \u0026aurora.Common{\n            Amount:      99.99,\n            Currency:    \"USD\",\n            Category:    \"ecommerce\",\n            Country:     \"US\",\n            Email:       \"john@doe.com\",\n            IPAddress:   \"127.0.0.1\",\n            UserID:      \"user_1234567890\",\n            MerchantID:  \"merch_1234567890\",\n            PaymentID:   \"pay_1234567890\",\n            ReferenceID: \"order_1234567890\",\n        },\n        Card: \u0026aurora.Card{\n            BinNumber: \"123456\",\n            Holder:    \"John Doe\",\n            Issuer:    \"Bank of America\",\n            LastFour:  \"1234\",\n            MCC:       \"5411\",\n            Network:   \"Visa\",\n            Token:     \"card_tok_1234567890\",\n            Type:      \"credit\",\n        },\n        Transfer: \u0026aurora.Transfer{\n            TransferType:    \"wallet_to_wallet\",\n            TransferPurpose: \"family_support\",\n            SenderName:      \"John Doe\",\n            SenderCountry:   \"US\",\n            ReceiverName:    \"Jane Smith\",\n            ReceiverCountry: \"GB\",\n        },\n    },\n})\n```\n\n### Response\n\n```go\ntype ProcessResponse struct {\n    Allow          bool          // transaction is allowed\n    AllowMessage   string        // message when allowed\n    Rejected       bool          // transaction is rejected\n    RejectMessage  string        // reason for rejection\n    NeedInspect    bool          // transaction needs manual review\n    InspectMessage string        // reason for inspection\n    Score          int           // risk score\n    Error          bool          // processing error occurred\n    ErrorMessage   string        // error details\n    ExecutionTime  time.Duration // rule execution duration\n}\n```\n\n### Transaction Fields\n\nThe `Transaction` struct uses nested sub-structs to organize fields by category. Only populate the sections relevant to your use case — all sub-struct pointers and fields use `omitempty`.\n\n#### Top-Level Scalar Fields\n\n| Field | JSON Key | Description |\n|---|---|---|\n| `Type` | `type` | Transaction type (e.g. `card`) |\n| `TransactionType` | `transaction_type` | Transaction action (e.g. `purchase`) |\n| `AccountAgeDays` | `account_age_days` | Account age in days |\n| `DeclinedCount` | `declined_count` | Number of declined transactions |\n| `IncomeMultiplier` | `income_multiplier` | Ratio of amount to registered income |\n| `IsFirstTransfer` | `is_first_transfer` | Whether this is the first transfer |\n| `IsNewDevice` | `is_new_device` | Whether a new device is used |\n| `IsNewIP` | `is_new_ip` | Whether a new IP is used |\n| `IsUnusualLocation` | `is_unusual_location` | Whether location is unusual |\n| `PasswordChangedRecently` | `password_changed_recently` | Recent password change flag |\n| `ProfileCompletion` | `profile_completion` | Profile completion percentage |\n| `RefundCount` | `refund_count` | Number of refunds |\n| `RefundRatio` | `refund_ratio` | Refund to transaction ratio |\n| `RegisteredIncome` | `registered_income` | User's registered income |\n| `TotalAmount24h` | `total_amount_24h` | Total transaction amount in 24h |\n| `TotalAmount7d` | `total_amount_7d` | Total transaction amount in 7 days |\n| `TransactionHour` | `transaction_hour` | Hour of the transaction |\n| `TransferCount24h` | `transfer_count_24h` | Number of transfers in 24h |\n| `UniqueRecipients` | `unique_recipients` | Number of unique recipients |\n\n#### Nested Sub-Structs\n\n| Sub-Struct | JSON Key | Fields |\n|---|---|---|\n| `Common` | `common` | `Amount`, `BrowserAgent`, `Category`, `ConnectionType`, `Country`, `Currency`, `Date`, `Description`, `DeviceFingerprint`, `DeviceID`, `Email`, `IPAddress`, `LastLoginIP`, `LastLoginTime`, `Latitude`, `Longitude`, `MerchantID`, `PaymentID`, `Phone`, `ReferenceID`, `UserID` |\n| `Card` | `card` | `BinNumber`, `Holder`, `Issuer`, `LastFour`, `MCC`, `Network`, `Token`, `Type` |\n| `Transfer` | `transfer` | `ExchangeRate`, `PaymentMethod`, `ReceiverAddress`, `ReceiverCountry`, `ReceiverIBAN`, `ReceiverIdentityPassport`, `ReceiverName`, `ReceiverSurname`, `ReceiverWalletID`, `Relationship`, `SenderAddress`, `SenderCountry`, `SenderIBAN`, `SenderIdentityPassport`, `SenderName`, `SenderSurname`, `SenderWalletID`, `SourceOfFunds`, `TargetCurrency`, `TransferPurpose`, `TransferType` |\n| `AccountChange` | `account_change` | `ChangeType`, `PreviousValueHash`, `TimeSinceLastChange`, `VerificationMethod` |\n| `AccountLogin` | `account_login` | `FailedAttempts`, `LoginMethod`, `LoginStatus`, `MFAMethod`, `MFAUsed`, `SessionID` |\n| `AccountOpening` | `account_opening` | `DocumentType`, `IdentityVerificationStatus`, `RegistrationMethod` |\n| `BNPL` | `bnpl` | `BNPLProvider`, `InstallmentCount`, `OutstandingBNPLAmount` |\n| `Crypto` | `crypto` | `CryptoAmount`, `CryptoCurrency`, `ExchangeName`, `IsSmartContract`, `WalletAddress` |\n| `Deposit` | `deposit` | `CheckNumber`, `DepositMethod`, `DepositSource`, `IsRemoteDeposit` |\n| `Invoice` | `invoice` | `InvoiceDueDate`, `InvoiceNumber`, `IsRecurringVendor`, `PurchaseOrderID`, `VendorID`, `VendorName` |\n| `Loan` | `loan` | `CreditScore`, `DebtToIncomeRatio`, `EmploymentStatus`, `LoanAmount`, `LoanTerm`, `LoanType` |\n| `P2P` | `p2p` | `PaymentNote`, `Platform`, `RecipientAccountAge` |\n| `Refund` | `refund` | `DaysSincePurchase`, `OriginalTransactionID`, `RefundMethod`, `RefundReason` |\n| `Withdrawal` | `withdrawal` | `AccountType`, `ATMID`, `DailyWithdrawalCount`, `WithdrawalMethod` |\n\n## Error Handling\n\nAPI errors are returned as `*aurora.APIError`:\n\n```go\nresp, err := client.Process.Execute(ctx, req)\nif err != nil {\n    var apiErr *aurora.APIError\n    if errors.As(err, \u0026apiErr) {\n        fmt.Printf(\"API error %d: %s\\n\", apiErr.StatusCode, apiErr.Message)\n    }\n    log.Fatal(err)\n}\n```\n\n## Callback\n\nSend a callback transaction using `client.Callback.Transaction()`.\n\n```go\nresp, err := client.Callback.Transaction(ctx, \u0026aurora.CallbackTransactionRequest{\n    Message:   \"Payment completed\",\n    PaymentID: \"pay_1234567890\",\n    Status:    \"success\",\n})\nif err != nil {\n    log.Fatal(err)\n}\n\nfmt.Printf(\"Success: %v | Message: %s\\n\", resp.Success, resp.Message)\n```\n\n### Request\n\n| Field | JSON Key | Description |\n|---|---|---|\n| `Message` | `message` | Callback message |\n| `PaymentID` | `payment_id` | Payment identifier |\n| `Status` | `status` | Transaction status |\n\n### Response\n\n```go\ntype CallbackTransactionResponse struct {\n    Success bool   // operation succeeded\n    Message string // response message\n}\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkintsdev%2Faurora-go-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkintsdev%2Faurora-go-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkintsdev%2Faurora-go-sdk/lists"}