税ルール取得
GET
/tax_rules/{tax_rule_id}
const url = 'https://api.smaregi.dev/TARGET-CONTRACT-ID/ec-b2b/tax_rules/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.smaregi.dev/TARGET-CONTRACT-ID/ec-b2b/tax_rules/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \ --header 'Authorization: Bearer <token>'税ルールを取得します。
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”tax_rule_id
required
string format: uuid
税ルールID
Responses
Section titled “Responses”取得成功
Media typeapplication/json
TaxRuleResponse
object
id
税ルールID
string format: uuid
taxRate
税率(%)
integer
calcRule
端数処理ルール
0: 処理無し1: 四捨五入2: 切り捨て3: 切り上げ
integer
taxCalcType
税計算タイプ
2: 明細単位3: 伝票単位
integer
applyAt
適用開始日時[YYYY-MM-DDThh:mm:ssTZD]
string format: date-time
Examples
Exampledefault
{ "id": "12345678-1234-1234-1234-1234567890ab", "taxRate": 10, "calcRule": 2, "taxCalcType": 3, "applyAt": "2019-10-01T00:00:00+09:00"}指定されたIDのリソースが見つからない場合
Media typeapplication/json
object
type
required
string
title
required
string
detail
string
status
integer
Example
{ "type": "about:blank", "title": "Not Found", "detail": "指定されたIDのリソースが見つかりません", "status": 404}