Skip to content

adibaulia/ovoid-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Un-Official Ovoid API Wrapper package for Go

Documentation Test-master Actions Status Go Report Card Ask Me Anything ! made-with-Go

Repository berikut ini merupakan porting dari ovoid untuk Go

Install

go get github.com/adibaulia/ovoid-go

Usage

Anda harus mendapatkan Token untuk menggunakan API Ovo.

Langkah 1

package main

import (
  ovo "github.com/adibaulia/ovoid-go"
)

func main(){
  login, err := ovo.NewOvoLogin("your_phone")
  if err != nil {
    ...
  }

  l, err := login.Login2FA()
  if err != nil {
    ...
  }

Langkah 2

  accessToken, err := login.Login2FAVerify(l.RefID, "your_verification_code")
  if err != nil {
    ...
  }

Langkah 3

  auth, err := login.LoginSecurityCode(accessToken.UpdateAccessToken)
  if err != nil {
      ...
  }
  YOUR_TOKEN := auth.Token

Lalu gunakan YOUR_TOKEN untuk menggunakan package ovoid. Contoh:

package main

import (
  ovo "github.com/adibaulia/ovoid-go"
)

func main(){
  o, err := ovo.NewClient("YOUR_TOKEN")
  if err != nil {
    ...
  }

  b, err := o.GetAllBalance()
  if err != nil {
    ...
  }
}

Progress

Masih dalam pengembangan. Silahkan Pull Request untuk berkontribusi.

Thank You !

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages