تصدير السجلات المحاسبية
curl --request GET \
--url https://api.truthlocks.com/v1/billing/exports/accounting \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.truthlocks.com/v1/billing/exports/accounting', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/billing/exports/accounting"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/billing/exports/accounting"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}<string>الفوترة
تصدير السجلات المحاسبية
GET
/
v1
/
billing
/
exports
/
accounting
تصدير السجلات المحاسبية
curl --request GET \
--url https://api.truthlocks.com/v1/billing/exports/accounting \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.truthlocks.com/v1/billing/exports/accounting', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/billing/exports/accounting"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/billing/exports/accounting"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}<string>تنزيل سجلات المحاسبة لتواريخ
from و to بتنسيق YYYY-MM-DD. النطاق الافتراضي هو آخر 30 يومًا. التنسيق الافتراضي هو csv؛ استخدم json لتصدير JSON. تعامل مع الاستجابة كملف وافحص نوع المحتوى الخاص به. يعود المعالج الحالي إلى الإعدادات الافتراضية للتواريخ غير القابلة للتحليل؛ تحقق من صحة التواريخ في عميلك.
