Skip to content

Commit

Permalink
Changed default language to english
Browse files Browse the repository at this point in the history
  • Loading branch information
febriliankr committed Jan 22, 2023
1 parent 14bd8c1 commit 6769672
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ go get github.com/febriliankr/[email protected]
wa := whatsapp.NewWhatsapp(token, myPhoneID)
```

Modifying instance
Modifying instance

- Changing the language `wa.Language = TemplateLanguage{ Code: "id" }`
- Changing the API version `wa.APIVersion = "v14.0"`
- Changing the Whatsapp Phone ID `wa.PhoneNumberID = WHATSAPP_PHONE_ID`
Expand Down Expand Up @@ -68,6 +69,7 @@ Check more usage example in example/example.go
## Getting the Whatsapp Cloud API Access

Official documentation:

- https://developers.facebook.com/docs/whatsapp?locale=en_US
- https://developers.facebook.com/docs/whatsapp/cloud-api/get-started
- Console: https://developers.facebook.com/apps/2017523718408931/whatsapp-business/wa-dev-console
Expand Down
4 changes: 2 additions & 2 deletions whatsapp.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ type Whatsapp struct {
Language TemplateLanguage
}

// Create new Whatsapp instance with v14.0 version and Indonesian as default language
// Create new Whatsapp instance with v14.0 version and English as default language
func NewWhatsapp(token string, phoneNumberID string) *Whatsapp {
return &Whatsapp{
Language: LanguageIndonesian,
Language: LanguageEnglish,
Token: token,
APIVersion: "v14.0",
PhoneNumberID: phoneNumberID,
Expand Down

0 comments on commit 6769672

Please sign in to comment.