Authorize business access
curl --request GET \
--url https://api.bachs.io/connect/oauth/authorizeconst options = {method: 'GET'};
fetch('https://api.bachs.io/connect/oauth/authorize', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.bachs.io/connect/oauth/authorize"
response = requests.get(url)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.bachs.io/connect/oauth/authorize"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"error": "invalid_client",
"error_description": "The client is not valid."
}{
"detail": "API key does not have permission for this operation",
"error_code": "FORBIDDEN"
}{
"detail": "Rate limit exceeded. Please retry after a few seconds.",
"error_code": "TOO_MANY_REQUESTS"
}Bachs Apps
Authorize business access
Redirects the merchant to sign in, select an existing independent business, and approve your preselected permissions. This is a browser navigation, with a ten-minute expiry. See Connect a business.
GET
/
connect
/
oauth
/
authorize
Authorize business access
curl --request GET \
--url https://api.bachs.io/connect/oauth/authorizeconst options = {method: 'GET'};
fetch('https://api.bachs.io/connect/oauth/authorize', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.bachs.io/connect/oauth/authorize"
response = requests.get(url)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.bachs.io/connect/oauth/authorize"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"error": "invalid_client",
"error_description": "The client is not valid."
}{
"detail": "API key does not have permission for this operation",
"error_code": "FORBIDDEN"
}{
"detail": "Rate limit exceeded. Please retry after a few seconds.",
"error_code": "TOO_MANY_REQUESTS"
}Query Parameters
Response
Redirects to Bachs sign-in/consent, or a validated callback carrying an OAuth error.

