Documentation
¶
Index ¶
- Constants
- func ExtractFreeeErrorMessage(errorString string) ([]string, error)
- func SetCompanyID(v *url.Values, companyID uint32)
- type AccountItem
- type AccountItems
- type Client
- func (c *Client) AuthCodeURL(state string, opts ...oauth2.AuthCodeOption) string
- func (c *Client) CreateDeal(ctx context.Context, oauth2Token *oauth2.Token, params DealCreateParams) (*Deal, *oauth2.Token, error)
- func (c *Client) CreateInvoice(ctx context.Context, oauth2Token *oauth2.Token, params InvoiceCreateParams) (*Invoice, *oauth2.Token, error)
- func (c *Client) CreateItem(ctx context.Context, oauth2Token *oauth2.Token, params ItemParams) (*Item, *oauth2.Token, error)
- func (c *Client) CreateManualJournal(ctx context.Context, oauth2Token *oauth2.Token, ...) (*ManualJournalResponse, *oauth2.Token, error)
- func (c *Client) CreatePartner(ctx context.Context, oauth2Token *oauth2.Token, params CreatePartnerParams) (*Partner, *oauth2.Token, error)
- func (c *Client) CreateReceipt(ctx context.Context, oauth2Token *oauth2.Token, params CreateReceiptParams, ...) (*ReceiptResponse, *oauth2.Token, error)
- func (c *Client) CreateSection(ctx context.Context, oauth2Token *oauth2.Token, params SectionParams) (*Section, *oauth2.Token, error)
- func (c *Client) CreateSegmentTag(ctx context.Context, oauth2Token *oauth2.Token, segmentID uint32, ...) (*SegmentTag, *oauth2.Token, error)
- func (c *Client) CreateTag(ctx context.Context, oauth2Token *oauth2.Token, params TagParams) (*Tag, *oauth2.Token, error)
- func (c *Client) DestroyDeal(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroyInvoice(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroyItem(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, itemID int32) (*oauth2.Token, error)
- func (c *Client) DestroyManualJournal(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroyPartner(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroySection(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroySegmentTag(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*oauth2.Token, error)
- func (c *Client) DestroyTag(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, tagID int32) (*oauth2.Token, error)
- func (c *Client) Exchange(ctx context.Context, code string, opts ...oauth2.AuthCodeOption) (*oauth2.Token, error)
- func (c *Client) GetAccountItems(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*AccountItems, *oauth2.Token, error)
- func (c *Client) GetCompany(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*CompanyResponse, *oauth2.Token, error)
- func (c *Client) GetDeal(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Deal, *oauth2.Token, error)
- func (c *Client) GetDeals(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*DealsResponse, *oauth2.Token, error)
- func (c *Client) GetInvoice(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Invoice, *oauth2.Token, error)
- func (c *Client) GetInvoices(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*InvoicesResponse, *oauth2.Token, error)
- func (c *Client) GetItems(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Items, *oauth2.Token, error)
- func (c *Client) GetManualJournals(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*ManualJournalsResponse, *oauth2.Token, error)
- func (c *Client) GetPartners(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Partners, *oauth2.Token, error)
- func (c *Client) GetReceipt(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*ReceiptResponse, *oauth2.Token, error)
- func (c *Client) GetSections(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32) (*Sections, *oauth2.Token, error)
- func (c *Client) GetSegmentTags(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*SegmentTags, *oauth2.Token, error)
- func (c *Client) GetTag(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, tagID uint32, ...) (*Tags, *oauth2.Token, error)
- func (c *Client) GetTags(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Tags, *oauth2.Token, error)
- func (c *Client) GetTaxCompanies(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32) (*TaxCompanies, *oauth2.Token, error)
- func (c *Client) GetUsersMe(ctx context.Context, oauth2Token *oauth2.Token, opts GetUsersMeOpts) (*Me, *oauth2.Token, error)
- func (c *Client) GetWalletTransaction(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, txnID uint64, ...) (*WalletTxn, *oauth2.Token, error)
- func (c *Client) GetWalletTransactions(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*WalletTxnsResponse, *oauth2.Token, error)
- func (c *Client) GetWalletable(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*Walletable, *oauth2.Token, error)
- func (c *Client) GetWalletables(ctx context.Context, oauth2Token *oauth2.Token, companyID uint32, ...) (*WalletablesResponse, *oauth2.Token, error)
- func (c *Client) UpdateDeal(ctx context.Context, oauth2Token *oauth2.Token, dealID uint64, ...) (*Deal, *oauth2.Token, error)
- func (c *Client) UpdateInvoice(ctx context.Context, oauth2Token *oauth2.Token, invoiceID int32, ...) (*Invoice, *oauth2.Token, error)
- func (c *Client) UpdateItem(ctx context.Context, oauth2Token *oauth2.Token, params ItemParams, ...) (*Item, *oauth2.Token, error)
- func (c *Client) UpdateManualJournal(ctx context.Context, oauth2Token *oauth2.Token, journalID int32, ...) (*ManualJournalResponse, *oauth2.Token, error)
- func (c *Client) UpdatePartner(ctx context.Context, oauth2Token *oauth2.Token, partnerID uint32, ...) (*Partner, *oauth2.Token, error)
- func (c *Client) UpdateSection(ctx context.Context, oauth2Token *oauth2.Token, sectionID uint32, ...) (*Section, *oauth2.Token, error)
- func (c *Client) UpdateSegmentTag(ctx context.Context, oauth2Token *oauth2.Token, segmentID uint32, id uint32, ...) (*SegmentTag, *oauth2.Token, error)
- func (c *Client) UpdateTag(ctx context.Context, oauth2Token *oauth2.Token, tagID uint32, params TagParams) (*Tag, *oauth2.Token, error)
- type Company
- type CompanyResponse
- type Config
- type CreateManualJournalParams
- type CreateManualJournalParamsDetail
- type CreatePartnerParams
- type CreatePartnerParamsAddressAttributes
- type CreatePartnerParamsPartnerBankAccountAttributes
- type CreatePartnerParamsPartnerDocSettingAttributes
- type CreatePartnerParamsPaymentTermAttributes
- type CreateReceiptParams
- type Deal
- type DealCreateParams
- type DealCreateParamsDetails
- type DealCreateParamsPayments
- type DealDetails
- type DealPayments
- type DealReceipts
- type DealRenews
- type DealResponse
- type DealUpdateParams
- type DealUpdateParamsDetails
- type DealUser
- type DealsResponse
- type DealsResponseMeta
- type Error
- type FiscalYears
- type FreeErrorMessageDetail
- type FreeeErrorMessage
- type GetAccountItemsOpts
- type GetCompanyOpts
- type GetDealOpts
- type GetInvoiceOpts
- type GetItemsOpts
- type GetManualJournalsOpts
- type GetPartnersOpts
- type GetReceiptOpts
- type GetSegmentTagsOpts
- type GetTagsOpts
- type GetUsersMeOpts
- type GetWalletTxnOpts
- type GetWalletablesOpts
- type Invoice
- type InvoiceContent
- type InvoiceCreateParams
- type InvoiceCreateParamsInvoiceContent
- type InvoiceResponse
- type InvoiceUpdateParams
- type InvoiceUpdateParamsInvoiceContent
- type InvoicesResponse
- type Item
- type ItemParams
- type ItemResponse
- type Items
- type Logger
- type ManualJournal
- type ManualJournalDetails
- type ManualJournalResponse
- type ManualJournalsResponse
- type Me
- type Meta
- type Partner
- type PartnerAddressAttributes
- type PartnerBankAccountAttributes
- type PartnerDocSettingAttributes
- type PartnerResponse
- type Partners
- type Receipt
- type ReceiptResponse
- type Receipts
- type Section
- type SectionParams
- type SectionResponse
- type Sections
- type SegmentTag
- type SegmentTagParams
- type SegmentTagResponse
- type SegmentTags
- type Tag
- type TagParams
- type TagResponse
- type Tags
- type TaxCompanies
- type TaxCompany
- type UnauthorizedError
- type UpdateManualJournalParams
- type UpdateManualJournalParamsDetails
- type UpdatePartnerParams
- type User
- type UserCompany
- type UserCreatedReceipt
- type WalletTxn
- type WalletTxnResponse
- type WalletTxnsResponse
- type Walletable
- type WalletableResponse
- type WalletablesResponse
Constants ¶
View Source
const ( HeaderXAPIVersion = "X-Api-Version" HeaderXFreeeRequestID = "X-Freee-Request-ID" APIEndpoint = "https://api.freee.co.jp" APIPath1 = "/api/1" XAPIVersion20200615 = "2020-06-15" )
View Source
const ( APIPathDeals = "deals" DealTypeIncome = "income" DealTypeExpense = "expense" DealStatusSettled = "settled" DealStatusUnsettled = "unsettled" DealDetailEntrySideCredit = "credit" DealDetailEntrySideDebit = "debit" )
View Source
const ()
View Source
const ( APIPathInvoices = "invoices" InvoiceStatusDraft = "draft" // 下書き InvoiceStatusApplying = "applying" // 申請中 InvoiceStatusRemanded = "remanded" // 差し戻し InvoiceStatusRejected = "rejected" // 却下 InvoiceStatusApproved = "approved" // 承認済み InvoiceStatusUnsubmitted = "unsubmitted" // 送付待ち InvoiceStatusSubmitted = "submitted" // 送付済み PaymentStatusNone = "" PaymentStatusUnsettled = "unsettled" // 入金待ち PaymentStatusSettled = "settled" // 入金済み PostingStatusNone = "" PostingStatusUnrequested = "unrequested" // リクエスト前 PostingStatusPreviewRegistered = "preview_registered" // プレビュー登録 PostingStatusPreviewFailed = "preview_failed" // プレビュー登録失敗 PostingStatusOrdered = "ordered" // 注文中 PostingStatusOrderFailed = "order_failed" // 注文失敗 PostingStatusPrinting = "printing" // 印刷中 PostingStatusCanceled = "canceled" // キャンセル PostingStatusPosted = "posted" // 投函済み PaymentTypeTransfer = "transfer" // 振込 PaymentTypeDirectDebit = "direct_debit" // 引き落とし InvoiceLayoutDefaultClassic = "default_classic" // レイアウト1/クラシック (デフォルト) InvoiceLayoutStandardClassic = "standard_classic" // レイアウト2/クラシック InvoiceLayoutEnvelopeClassic = "envelope_classic" // 封筒1/クラシック InvoiceLayoutCarriedForwardStandardClassic = "carried_forward_standard_classic" // レイアウト3(繰越金額欄あり)/クラシック InvoiceLayoutCarriedForwardEnvelopeClassic = "carried_forward_envelope_classic" // 封筒2(繰越金額欄あり)/クラシック InvoiceLayoutDefaultModern = "default_modern" // レイアウト1/モダン InvoiceLayoutStandardModern = "standard_modern" // レイアウト2/モダン InvoiceLayoutEnvelopeModern = "envelope_modern" // 封筒/モダン TaxEntryMethodInclusive = "inclusive" // 内税 TaxEntryMethodExclusive = "exclusive" // 外税 InvoiceContentTypeNormal = "normal" InvoiceContentTypeDiscount = "discount" InvoiceContentTypeText = "text" UseVirtualTransferAccountNotUse = "not_use" // 利用しない UseVirtualTransferAccountUse = "use" // 利用する )
View Source
const ( APIPathManualJournals = "manual_journals" ManualJournalEntrySideCredit = "credit" ManualJournalEntrySideDebit = "debit" )
View Source
const ( Oauth2TokenURL = "https://accounts.secure.freee.co.jp/public_api/token" Oauth2AuthURL = "https://accounts.secure.freee.co.jp/public_api/authorize" )
View Source
const ( APIPathPartners = "partners" // 口座種別 // ordinary:普通 BankAccountAccountTypeOrdinary = "ordinary" // checking:当座 BankAccountAccountTypeChecking = "checking" // earmarked:納税準備預金 BankAccountAccountTypeEarmarked = "earmarked" // savings:貯蓄 BankAccountAccountTypeSavings = "savings" // other:その他 BankAccountAccountTypeOther = "other" )
View Source
const ( APIPathSegments = "segments" SegmentID1 = uint32(1) SegmentID2 = uint32(2) SegmentID3 = uint32(3) )
View Source
const ( APIPathTaxes = "taxes" // tax_5: 5%表示の税区分 TaxRate5 = "tax_5" // tax_8: 8%表示の税区分 TaxRate8 = "tax_8" // tax_r8: 軽減税率8%表示の税区分 TaxRateR8 = "tax_r8" // tax_10: 10%表示の税区分 TaxRate10 = "tax_10" )
View Source
const ( APIPathTxns = "wallet_txns" WalletTypeBankAccount = "bank_account" WalletTypeCreditCard = "credit_card" WalletTypeWallet = "wallet" //現金 TxnsTypeIncome = "income" TxnsTypeExpense = "expense" )
View Source
const (
APIPathAccountItems = "account_items"
)
View Source
const (
APIPathCompanies = "companies"
)
View Source
const (
APIPathItems = "items"
)
View Source
const (
APIPathReceipts = "receipts"
)
View Source
const (
APIPathSections = "sections"
)
View Source
const (
APIPathTags = "tags"
)
View Source
const (
APIPathUsers = "users"
)
View Source
const (
APIPathWalletables = "walletables"
)
Variables ¶
This section is empty.
Functions ¶
func SetCompanyID ¶
Types ¶
type AccountItem ¶
type AccountItem struct { // 勘定科目ID ID int32 `json:"id"` // 勘定科目名 (30文字以内) Name string `json:"name"` // ショートカット1 (20文字以内) Shortcut *string `json:"shortcut,omitempty"` // ショートカット2(勘定科目コード) (20文字以内) ShortcutNum *string `json:"shortcut_num,omitempty"` // 税区分コード TaxCode int32 `json:"tax_code"` // デフォルト設定がされている税区分ID DefaultTaxID int32 `json:"default_tax_id,omitempty"` // デフォルト設定がされている税区分コード DefaultTaxCode int32 `json:"default_tax_code"` // 勘定科目カテゴリー AccountCategory string `json:"account_category"` // 勘定科目のカテゴリーID AccountCategoryID int32 `json:"account_category_id"` Categories []string `json:"categories"` // 勘定科目の使用設定(true: 使用する、false: 使用しない) Available bool `json:"available"` // 口座ID WalletableID *int32 `json:"walletable_id"` // 決算書表示名(小カテゴリー) GroupName *string `json:"group_name,omitempty"` // 収入取引相手勘定科目名 CorrespondingIncomeName *string `json:"corresponding_income_name,omitempty"` // 収入取引相手勘定科目ID CorrespondingIncomeID *int32 `json:"corresponding_income_id,omitempty"` // 支出取引相手勘定科目名 CorrespondingExpenseName *string `json:"corresponding_expense_name,omitempty"` // 支出取引相手勘定科目ID CorrespondingExpenseID *int32 `json:"corresponding_expense_id,omitempty"` }
type AccountItems ¶
type AccountItems struct {
AccountItems []AccountItem `json:"account_items"`
}
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client represents an API client for freee.
func (*Client) AuthCodeURL ¶
func (c *Client) AuthCodeURL(state string, opts ...oauth2.AuthCodeOption) string
func (*Client) CreateDeal ¶
func (*Client) CreateInvoice ¶
func (*Client) CreateItem ¶
func (*Client) CreateManualJournal ¶
func (c *Client) CreateManualJournal( ctx context.Context, oauth2Token *oauth2.Token, params CreateManualJournalParams, ) (*ManualJournalResponse, *oauth2.Token, error)
func (*Client) CreatePartner ¶
func (*Client) CreateReceipt ¶
func (*Client) CreateSection ¶
func (*Client) CreateSegmentTag ¶
func (*Client) DestroyDeal ¶
func (*Client) DestroyInvoice ¶
func (*Client) DestroyItem ¶
func (*Client) DestroyManualJournal ¶
func (*Client) DestroyPartner ¶
func (*Client) DestroySection ¶
func (*Client) DestroySegmentTag ¶
func (*Client) DestroyTag ¶
func (*Client) GetAccountItems ¶
func (*Client) GetCompany ¶
func (*Client) GetInvoice ¶
func (*Client) GetInvoices ¶
func (*Client) GetManualJournals ¶
func (*Client) GetPartners ¶
func (*Client) GetReceipt ¶
func (*Client) GetSections ¶
func (*Client) GetSegmentTags ¶
func (*Client) GetTaxCompanies ¶
func (*Client) GetUsersMe ¶
func (*Client) GetWalletTransaction ¶
func (*Client) GetWalletTransactions ¶
func (*Client) GetWalletable ¶
func (*Client) GetWalletables ¶
func (*Client) UpdateDeal ¶
func (*Client) UpdateInvoice ¶
func (*Client) UpdateItem ¶
func (*Client) UpdateManualJournal ¶
func (*Client) UpdatePartner ¶
func (*Client) UpdateSection ¶
func (*Client) UpdateSegmentTag ¶
type Company ¶
type Company struct { // 事業所ID ID int32 `json:"id"` // 事業所の正式名称 (100文字以内) Name *string `json:"name"` // 正式名称フリガナ (100文字以内) NameKana *string `json:"name_kana"` // 事業所名 DisplayName string `json:"display_name"` // 源泉徴収税計算(0: 消費税を含める、1: 消費税を含めない) TaxAtSourceCalcType int32 `json:"tax_at_source_calc_type"` // 担当者名 (50文字以内) ContactName *string `json:"contact_name"` // 従業員数(0: 経営者のみ、1: 2~5人、2: 6~10人、3: 11~20人、4: 21~30人、5: 31~40人、6: 41~100人、7: 100人以上 HeadCount *int32 `json:"head_count"` // 法人番号 (半角数字13桁、法人のみ) CorporateNumber string `json:"corporate_number"` // 仕訳番号形式(not_used: 使用しない、digits: 数字(例:5091824)、alnum: 英数字(例:59J0P)) TxnNumberFormat string `json:"txn_number_format"` // 決済口座のデフォルト DefaultWalletAccountId *int32 `json:"default_wallet_account_id,omitempty"` // プライベート資金/役員資金(false: 使用しない、true: 使用する) PrivateSettlement bool `json:"private_settlement"` // マイナスの表示方法(0: -、 1: △) MinusFormat int32 `json:"minus_format"` // ユーザーの権限 Role string `json:"role"` // 電話番号1 Phone1 string `json:"phone1"` // 電話番号2 Phone2 *string `json:"phone2"` // FAX Fax *string `json:"fax"` // 郵便番号 Zipcode string `json:"zipcode"` // 都道府県コード(-1: 設定しない、0: 北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄 PrefectureCode *int32 `json:"prefecture_code"` // 市区町村・番地 StreetName1 string `json:"street_name1"` // 建物名・部屋番号など StreetName2 string `json:"street_name2"` // 請求書レイアウト * `default_classic` - レイアウト1/クラシック (デフォルト) * `standard_classic` - レイアウト2/クラシック * `envelope_classic` - 封筒1/クラシック * `carried_forward_standard_classic` - レイアウト3(繰越金額欄あり)/クラシック * `carried_forward_envelope_classic` - 封筒2(繰越金額欄あり)/クラシック * `default_modern` - レイアウト1/モダン * `standard_modern` - レイアウト2/モダン * `envelope_modern` - 封筒/モダン InvoiceLayout string `json:"invoice_layout"` // 金額端数処理方法(0: 切り捨て、1: 切り上げ、2: 四捨五入) AmountFraction int32 `json:"amount_fraction"` // 種別(agriculture_forestry_fisheries_ore: 農林水産業/鉱業、construction: 建設、manufacturing_processing: 製造/加工、it: IT、transportation_logistics: 運輸/物流、retail_wholesale: 小売/卸売、finance_insurance: 金融/保険、real_estate_rental: 不動産/レンタル、profession: 士業/学術/専門技術サービス、design_production: デザイン/制作、food: 飲食、leisure_entertainment: レジャー/娯楽、lifestyle: 生活関連サービス、education: 教育/学習支援、medical_welfare: 医療/福祉、other_services: その他サービス、other: その他) IndustryClass string `json:"industry_class"` // 業種(agriculture: 農業, forestry: 林業, fishing_industry: 漁業、水産養殖業, mining: 鉱業、採石業、砂利採取業, civil_contractors: 土木工事業, pavement: 舗装工事業, carpenter: とび、大工、左官等の建設工事業, renovation: リフォーム工事業, electrical_plumbing: 電気、管工事等の設備工事業, grocery: 食料品の製造加工業, machinery_manufacturing: 機械器具の製造加工業, printing: 印刷業, other_manufacturing: その他の製造加工業, software_development: 受託:ソフトウェア、アプリ開発業, system_development: 受託:システム開発業, survey_analysis: 受託:調査、分析等の情報処理業, server_management: 受託:サーバー運営管理, website_production: 受託:ウェブサイト制作, online_service_management: オンラインサービス運営業, online_advertising_agency: オンライン広告代理店業, online_advertising_planning_production: オンライン広告企画・制作業, online_media_management: オンラインメディア運営業, portal_site_management: ポータルサイト運営業, other_it_services: その他、IT サービス業, transport_delivery: 輸送業、配送業, delivery: バイク便等の配達業, other_transportation_logistics: その他の運輸業、物流業, other_wholesale: 卸売業:その他, clothing_wholesale_fiber: 卸売業:衣類卸売/繊維, food_wholesale: 卸売業:飲食料品, entrusted_development_wholesale: 卸売業:機械器具, online_shop: 小売業:無店舗 オンラインショップ, fashion_grocery_store: 小売業:店舗あり ファッション、雑貨, food_store: 小売業:店舗あり 生鮮食品、飲食料品, entrusted_store: 小売業:店舗あり 機械、器具, other_store: 小売業:店舗あり その他, financial_instruments_exchange: 金融業:金融商品取引, commodity_futures_investment_advisor: 金融業:商品先物取引、商品投資顧問, other_financial: 金融業:その他, brokerage_insurance: 保険業:仲介、代理, other_insurance: 保険業:その他, real_estate_developer: 不動産業:ディベロッパー, real_estate_brokerage: 不動産業:売買、仲介, rent_coin_parking_management: 不動産業:賃貸、コインパーキング、管理, rental_office_co_working_space: 不動産業:レンタルオフィス、コワーキングスペース, rental_lease: レンタル業、リース業, cpa_tax_accountant: 士業:公認会計士事務所、税理士事務所, law_office: 士業:法律事務所, judicial_and_administrative_scrivener: 士業:司法書士事務所/行政書士事務所, labor_consultant: 士業:社会保険労務士事務所, other_profession: 士業:その他, business_consultant: 経営コンサルタント, academic_research_development: 学術・開発研究機関, advertising_agency: 広告代理店, advertising_planning_production: 広告企画/制作, design_development: ソフトウェア、アプリ開発業(受託), apparel_industry_design: 服飾デザイン業、工業デザイン業, website_design: ウェブサイト制作(受託), advertising_planning_design: 広告企画/制作業, other_design: その他、デザイン/制作, restaurants_coffee_shops: レストラン、喫茶店等の飲食店業, sale_of_lunch: 弁当の販売業, bread_confectionery_manufacture_sale: パン、菓子等の製造販売業, delivery_catering_mobile_catering: デリバリー業、ケータリング業、移動販売業, hotel_inn: 宿泊業:ホテル、旅館, homestay: 宿泊業:民泊, travel_agency: 旅行代理店業, leisure_sports_facility_management: レジャー、スポーツ等の施設運営業, show_event_management: ショー、イベント等の興行、イベント運営業, barber: ビューティ、ヘルスケア業:床屋、理容室, beauty_salon: ビューティ、ヘルスケア業:美容室, spa_sand_bath_sauna: ビューティ、ヘルスケア業:スパ、砂風呂、サウナ等, este_ail_salon: ビューティ、ヘルスケア業:その他、エステサロン、ネイルサロン等, bridal_planning_introduce_wedding: 冠婚葬祭業:ブライダルプランニング、結婚式場紹介等, memorial_ceremony_funeral: 冠婚葬祭業:メモリアルセレモニー、葬儀等, moving: 引っ越し業, courier_industry: 宅配業, house_maid_cleaning_agency: 家事代行サービス業:無店舗 ハウスメイド、掃除代行等, re_tailoring_clothes: 家事代行サービス業:店舗あり 衣類修理、衣類仕立て直し等, training_institute_management: 研修所等の施設運営業, tutoring_school: 学習塾、進学塾等の教育・学習支援業, music_calligraphy_abacus_classroom: 音楽教室、書道教室、そろばん教室等のの教育・学習支援業, english_school: 英会話スクール等の語学学習支援業, tennis_yoga_judo_school: テニススクール、ヨガ教室、柔道場等のスポーツ指導、支援業, culture_school: その他、カルチャースクール等の教育・学習支援業, seminar_planning_management: セミナー等の企画、運営業, hospital_clinic: 医療業:病院、一般診療所、クリニック等, dental_clinic: 医療業:歯科診療所, other_medical_services: 医療業:その他、医療サービス等, nursery: 福祉業:保育所等、児童向け施設型サービス, nursing_home: 福祉業:老人ホーム等、老人向け施設型サービス, rehabilitation_support_services: 福祉業:療育支援サービス等、障害者等向け施設型サービス, other_welfare: 福祉業:その他、施設型福祉サービス, visit_welfare_service: 福祉業:訪問型福祉サービス, recruitment_temporary_staffing: 人材紹介業、人材派遣業, life_related_recruitment_temporary_staffing: 生活関連サービスの人材紹介業、人材派遣業, car_maintenance_car_repair: 自動車整備業、自動車修理業, machinery_equipment_maintenance_repair: 機械機器類の整備業、修理業, cleaning_maintenance_building_management: 清掃業、メンテナンス業、建物管理業, security: 警備業, other_services: その他のサービス業, npo: NPO, general_incorporated_association: 一般社団法人, general_incorporated_foundation: 一般財団法人, other_association: その他組織) IndustryCode string `json:"industry_code"` // 仕訳承認フロー(enable: 有効、 disable: 無効) WorkflowSetting string `json:"workflow_setting"` // 取引先コードの利用設定(true: 有効、 false: 無効) UsePartnerCode bool `json:"use_partner_code"` FiscalYears []FiscalYears `json:"fiscal_years"` }
type CompanyResponse ¶
type CompanyResponse struct {
Company Company `json:"company"`
}
type CreateManualJournalParams ¶
type CreateManualJournalParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 仕訳番号 TxnNumber string `json:"txn_number,omitempty"` // 決算整理仕訳フラグ(falseまたは未指定の場合: 日常仕訳) Adjustment bool `json:"adjustment,omitempty"` CreateManualJournalParamsDetails []CreateManualJournalParamsDetail `json:"details"` // 証憑ファイルID(ファイルボックスのファイルID)(配列) ReceiptIDs []uint64 `json:"receipt_ids,omitempty"` }
type CreateManualJournalParamsDetail ¶
type CreateManualJournalParamsDetail struct { // 貸借(貸方: credit, 借方: debit) EntrySide string `json:"entry_side"` // 税区分コード TaxCode int32 `json:"tax_code"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 取引金額(税込で指定してください) Amount uint64 `json:"amount"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` // 取引先ID PartnerID int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode string `json:"partner_code,omitempty"` // 品目ID ItemID int32 `json:"item_id,omitempty"` // 部門ID SectionID int32 `json:"section_id,omitempty"` // メモタグID TagIDs []int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID uint64 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID uint64 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID uint64 `json:"segment_3_tag_id,omitempty"` // 備考 Description string `json:"description,omitempty"` }
type CreatePartnerParams ¶
type CreatePartnerParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 取引先名 (255文字以内) Name string `json:"name"` // 取引先コード(取引先コードの利用を有効にしている場合は、codeの指定は必須です。) Code string `json:"code,omitempty"` // ショートカット1 (255文字以内) Shortcut1 string `json:"shortcut1,omitempty"` // ショートカット2 (255文字以内) Shortcut2 string `json:"shortcut2,omitempty"` // 事業所種別(null: 未設定、1: 法人、2: 個人) OrgCode *int32 `json:"org_code,omitempty"` // 地域(JP: 国内、ZZ:国外) CountryCode string `json:"country_code,omitempty"` // 正式名称(255文字以内) LongName string `json:"long_name,omitempty"` // カナ名称(255文字以内) NameKana string `json:"name_kana,omitempty"` // 敬称(御中、様、(空白)の3つから選択) DefaultTitle string `json:"default_title,omitempty"` // 電話番号 Phone string `json:"phone,omitempty"` // 担当者 氏名 (255文字以内) ContactName string `json:"contact_name,omitempty"` // 担当者 メールアドレス (255文字以内) Email string `json:"email,omitempty"` // 振込元口座ID(一括振込ファイル用):(walletableのtypeが'bank_account'のidのみ指定できます。また、未設定にする場合は、nullを指定してください。) PayerWalletableID *int32 `json:"payer_walletable_id,omitempty"` // 振込手数料負担(一括振込ファイル用): (振込元(当方): payer, 振込先(先方): payee) TransferFeeHandlingSide string `json:"transfer_fee_handling_side,omitempty"` AddressAttributes CreatePartnerParamsAddressAttributes `json:"address_attributes,omitempty"` PartnerDocSettingAttributes CreatePartnerParamsPartnerDocSettingAttributes `json:"partner_doc_setting_attributes,omitempty"` PartnerBankAccountAttributes CreatePartnerParamsPartnerBankAccountAttributes `json:"partner_bank_account_attributes,omitempty"` PaymentTermAttributes CreatePartnerParamsPaymentTermAttributes `json:"payment_term_attributes,omitempty"` InvoicePaymentTermAttributes CreatePartnerParamsPaymentTermAttributes `json:"invoice_payment_term_attributes,omitempty"` }
type CreatePartnerParamsAddressAttributes ¶
type CreatePartnerParamsAddressAttributes struct { // 郵便番号(8文字以内) Zipcode string `json:"zipcode,omitempty"` // 都道府県コード(0: 北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄 PrefectureCode int32 `json:"prefecture_code,omitempty"` // 市区町村・番地(255文字以内) StreetName1 string `json:"street_name1,omitempty"` // 建物名・部屋番号など(255文字以内) StreetName2 string `json:"street_name2,omitempty"` }
type CreatePartnerParamsPartnerBankAccountAttributes ¶
type CreatePartnerParamsPartnerBankAccountAttributes struct { // 銀行名 BankName string `json:"bank_name,omitempty"` // 銀行名(カナ) BankNameKana string `json:"bank_name_kana,omitempty"` // 銀行番号 BankCode string `json:"bank_code,omitempty"` // 支店名 BranchName string `json:"branch_name,omitempty"` // 支店名(カナ) BranchKana string `json:"branch_kana,omitempty"` // 支店番号 BranchCode string `json:"branch_code,omitempty"` // 口座種別(ordinary:普通、checking:当座、earmarked:納税準備預金、savings:貯蓄、other:その他) AccountType string `json:"account_type,omitempty"` // 口座番号 AccountNumber string `json:"account_number,omitempty"` // 受取人名 LongAccountName string `json:"long_account_name,omitempty"` // 受取人名(カナ) AccountName string `json:"account_name,omitempty"` }
type CreatePartnerParamsPartnerDocSettingAttributes ¶
type CreatePartnerParamsPartnerDocSettingAttributes struct { // 請求書送付方法(email:メール、posting:郵送、email_and_posting:メールと郵送) SendingMethod string `json:"sending_method,omitempty"` }
type CreatePartnerParamsPaymentTermAttributes ¶
type CreatePartnerParamsPaymentTermAttributes struct { // 締め日(29, 30, 31日の末日を指定する場合は、32を指定してください。) CutoffDay int32 `json:"cutoff_day,omitempty"` // 支払月 AdditionalMonths int32 `json:"additional_months,omitempty"` // 支払日(29, 30, 31日の末日を指定する場合は、32を指定してください。) FixedDay int32 `json:"fixed_day,omitempty"` }
type CreateReceiptParams ¶
type Deal ¶
type Deal struct { // 取引ID ID uint64 `json:"id"` // 事業所ID CompanyID int32 `json:"company_id"` // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 支払期日 (yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 金額 Amount int32 `json:"amount"` // 支払金額 DueAmount *int32 `json:"due_amount,omitempty"` // 収支区分 (収入: income, 支出: expense) Type *string `json:"type,omitempty"` // 取引先ID PartnerID int32 `json:"partner_id"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 管理番号 RefNumber *string `json:"ref_number,omitempty"` // 決済状況 (未決済: unsettled, 完了: settled) Status string `json:"status"` // 取引の明細行 Details *[]DealDetails `json:"details,omitempty"` // 取引の+更新行 Renews *[]DealRenews `json:"renews,omitempty"` // 取引の支払行 Payments *[]DealPayments `json:"payments,omitempty"` // 証憑ファイル Receipts *[]DealReceipts `json:"receipts,omitempty"` }
type DealCreateParams ¶
type DealCreateParams struct { // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 収支区分 (収入: income, 支出: expense) Type string `json:"type"` // 事業所ID CompanyID int32 `json:"company_id"` // 支払期日(yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 取引先ID PartnerID *int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 管理番号 RefNumber *string `json:"ref_number,omitempty"` Details []DealCreateParamsDetails `json:"details"` // 支払行一覧(配列):未指定の場合、未決済の取引を作成します。 Payments *[]DealCreateParamsPayments `json:"payments,omitempty"` // 証憑ファイルID(配列) ReceiptIDs *[]int32 `json:"receipt_ids,omitempty"` }
type DealCreateParamsDetails ¶
type DealCreateParamsDetails struct { // 税区分コード TaxCode int32 `json:"tax_code"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 取引金額(税込で指定してください) Amount int32 `json:"amount"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // メモタグID TagIDs *[]int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID *int32 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID *int32 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID *int32 `json:"segment_3_tag_id,omitempty"` // 備考 Description *string `json:"description,omitempty"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` }
type DealCreateParamsPayments ¶
type DealCreateParamsPayments struct { // 支払金額:payments指定時は必須 Amount int32 `json:"amount"` // 口座ID(from_walletable_typeがprivate_account_itemの場合は勘定科目ID):payments指定時は必須 FromWalletableID int32 `json:"from_walletable_id"` // 口座区分 (銀行口座: bank_account, クレジットカード: credit_card, 現金: wallet, プライベート資金(法人の場合は役員借入金もしくは役員借入金、個人の場合は事業主貸もしくは事業主借): private_account_item):payments指定時は必須 FromWalletableType string `json:"from_walletable_type"` // 支払日:payments指定時は必須 Date string `json:"date"` }
type DealDetails ¶
type DealDetails struct { ID uint64 `json:"id"` // 税区分コード TaxCode int32 `json:"tax_code"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 取引金額(税込で指定してください) Amount int32 `json:"amount"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // メモタグID TagIDs *[]int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID *int32 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID *int32 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID *int32 `json:"segment_3_tag_id,omitempty"` // 備考 Description *string `json:"description,omitempty"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` // 貸借(貸方: credit, 借方: debit) EntrySide string `json:"entry_side"` }
type DealPayments ¶
type DealPayments struct { // 取引行ID ID uint64 `json:"id"` // 支払日 Date string `json:"date"` // 口座区分 (銀行口座: bank_account, クレジットカード: credit_card, 現金: wallet, プライベート資金(法人の場合は役員借入金もしくは役員借入金、個人の場合は事業主貸もしくは事業主借): private_account_item) FromWalletableType string `json:"from_walletable_type,omitempty"` // 口座ID(from_walletable_typeがprivate_account_itemの場合は勘定科目ID) FromWalletableID int32 `json:"from_walletable_id,omitempty"` // 支払金額 Amount int32 `json:"amount"` }
type DealReceipts ¶
type DealReceipts struct { // 証憑ID ID int32 `json:"id"` // ステータス(unconfirmed:確認待ち、confirmed:確認済み、deleted:削除済み、ignored:無視) Status string `json:"status"` // メモ Description *string `json:"description,omitempty"` // MIMEタイプ MimeType string `json:"mime_type"` // 発生日 IssueDate *string `json:"issue_date,omitempty"` // アップロード元種別 Origin string `json:"origin"` // 作成日時(ISO8601形式) CreatedAt string `json:"created_at"` // ファイルのダウンロードURL(freeeにログインした状態でのみ閲覧可能です。) <br> <br> file_srcは廃止予定の属性になります。<br> file_srcに替わり、証憑ファイルのダウンロード APIをご利用ください。<br> 証憑ファイルのダウンロードAPIを利用することで、以下のようになります。 <ul> <li>アプリケーション利用者はfreee APIアプリケーションにログインしていれば、証憑ダウンロード毎にfreeeに改めてログインすることなくファイルが参照できるようになります。</li> </ul> FileSrc string `json:"file_src"` User DealUser `json:"user"` }
type DealRenews ¶
type DealRenews struct { // +更新行ID ID uint64 `json:"id"` // 更新日 (yyyy-mm-dd) UpdateDate string `json:"update_date"` // +更新の対象行ID RenewTargetId int64 `json:"renew_target_id"` // +更新の対象行タイプ RenewTargetType string `json:"renew_target_type"` // +更新の明細行一覧(配列) Details []DealDetails `json:"details"` }
type DealResponse ¶
type DealResponse struct {
Deal Deal `json:"deal"`
}
type DealUpdateParams ¶
type DealUpdateParams struct { // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 収支区分 (収入: income, 支出: expense) Type string `json:"type"` // 事業所ID CompanyID int32 `json:"company_id"` // 支払期日(yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 取引先ID PartnerID *int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 管理番号 RefNumber *string `json:"ref_number,omitempty"` Details []DealUpdateParamsDetails `json:"details"` // 証憑ファイルID(配列) ReceiptIDs []int32 `json:"receipt_ids,omitempty"` }
type DealUpdateParamsDetails ¶
type DealUpdateParamsDetails struct { // 取引行ID: 既存取引行を更新する場合に指定します。IDを指定しない取引行は、新規行として扱われ追加されます。また、detailsに含まれない既存の取引行は削除されます。更新後も残したい行は、必ず取引行IDを指定してdetailsに含めてください。 ID *uint64 `json:"id,omitempty"` // 税区分コード TaxCode int32 `json:"tax_code"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 取引金額(税込で指定してください) Amount int32 `json:"amount"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // メモタグID TagIDs *[]int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID *int32 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID *int32 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID *int32 `json:"segment_3_tag_id,omitempty"` // 備考 Description *string `json:"description,omitempty"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` }
type DealsResponse ¶
type DealsResponse struct { Deals []Deal `json:"deals"` Meta DealsResponseMeta `json:"meta"` }
type DealsResponseMeta ¶
type DealsResponseMeta struct {
TotalCount int32 `json:"total_count"`
}
type FiscalYears ¶
type FiscalYears struct { // 製造業向け機能(true: 使用する、false: 使用しない) UseIndustryTemplate bool `json:"use_industry_template"` // 固定資産の控除法(true: 間接控除法、false: 直接控除法) IndirectWriteOffMethod bool `json:"indirect_write_off_method"` // 期首日 StartDate *string `json:"start_date,omitempty"` // 期末日 EndDate *string `json:"end_date,omitempty"` // 月次償却(0: しない、1: する) DepreciationRecordMethod int32 `json:"depreciation_record_method"` // 課税区分(0: 免税、1: 簡易課税、2: 本則課税(個別対応方式)、3: 本則課税(一括比例配分方式)、4: 本則課税(全額控除)) TaxMethod int32 `json:"tax_method"` // 簡易課税用事業区分(0: 第一種:卸売業、1: 第二種:小売業、2: 第三種:農林水産業、工業、建設業、製造業など、3: 第四種:飲食店業など、4: 第五種:金融・保険業、運輸通信業、サービス業など、5: 第六種:不動産業など SalesTaxBusinessCode int32 `json:"sales_tax_business_code"` // 消費税端数処理方法(0: 切り捨て、1: 切り上げ、2: 四捨五入) TaxFraction int32 `json:"tax_fraction"` // 消費税経理処理方法(0: 税込経理、1: 旧税抜経理、2: 税抜経理) TaxAccountMethod int32 `json:"tax_account_method"` // 不動産所得使用区分(0: 一般、3: 一般/不動産) ※個人事業主のみ設定可能 ReturnCode int32 `json:"return_code"` }
FiscalYears struct for FiscalYears
type FreeErrorMessageDetail ¶
type FreeErrorMessageDetail struct {
Messages []string `json:"messages"`
}
type FreeeErrorMessage ¶
type FreeeErrorMessage struct { ErrorDescription string `json:"error_description"` Message string `json:"message"` Messages []string `json:"messages"` ErrorDetails []FreeErrorMessageDetail `json:"errors"` }
type GetAccountItemsOpts ¶
type GetAccountItemsOpts struct {
BaseDate string `url:"base_date,omitempty"`
}
type GetCompanyOpts ¶
type GetDealOpts ¶
type GetDealOpts struct { // 取引先ID PartnerID int32 `url:"partner_id,omitempty"` // 決済状況 (未決済: unsettled, 完了: settled) Status string `url:"status,omitempty"` // 収支区分 (収入: income, 支出: expense) Type string `url:"type,omitempty"` // 発生日で絞込:開始日(yyyy-mm-dd) StartIssueDate string `url:"start_issue_date,omitempty"` // 発生日で絞込:終了日(yyyy-mm-dd) EndIssueDate string `url:"end_issue_date,omitempty"` // 取引の債権債務行の表示(without: 表示しない(デフォルト), with: 表示する) Accruals string `url:"accruals,omitempty"` Offset uint32 `url:"offset,omitempty"` Limit uint32 `url:"limit,omitempty"` }
type GetInvoiceOpts ¶
type GetInvoiceOpts struct { // 事業所ID CompanyID int32 `url:"company_id"` // 取引先IDで絞込 PartnerID int32 `url:"partner_id,omitempty"` // 取引先コードで絞込 PartnerCode string `url:"partner_code,omitempty"` // 請求日の開始日(yyyy-mm-dd) StartIssueDate string `url:"start_issue_date,omitempty"` // 請求日の終了日(yyyy-mm-dd) EndIssueDate string `url:"end_issue_date,omitempty"` // 期日の開始日(yyyy-mm-dd) StartDueDate string `url:"start_due_date,omitempty"` // 期日の終了日(yyyy-mm-dd) EndDueDate string `url:"end_due_date,omitempty"` // 請求書番号 InvoiceNumber string `url:"invoice_number,omitempty"` // 概要 Description string `url:"description,omitempty"` // 請求書ステータス (draft: 下書き, applying: 申請中, remanded: 差し戻し, rejected: 却下, approved: 承認済み, unsubmitted: 送付待ち, submitted: 送付済み) InvoiceStatus string `url:"invoice_status,omitempty"` // 入金ステータス (unsettled: 入金待ち, settled: 入金済み) PaymentStatus string `url:"payment_status,omitempty"` // 取得レコードのオフセット (デフォルト: 0) Offset uint32 `url:"offset,omitempty"` // 取得レコードの件数 (デフォルト: 20, 最大: 100) Limit uint32 `url:"limit,omitempty"` }
type GetItemsOpts ¶
type GetManualJournalsOpts ¶
type GetManualJournalsOpts struct { // 発生日で絞込:開始日(yyyy-mm-dd) StartIssueDate string `url:"start_issue_date,omitempty"` // 発生日で絞込:終了日(yyyy-mm-dd) EndIssueDate string `url:"end_issue_date,omitempty"` // 貸借で絞込 (貸方: credit, 借方: debit) EntrySide string `url:"entry_side,omitempty"` Offset uint32 `url:"offset,omitempty"` Limit uint32 `url:"limit,omitempty"` }
type GetPartnersOpts ¶
type GetReceiptOpts ¶
type GetReceiptOpts struct { StartDate string `url:"start_date"` EndDate string `url:"end_date"` UserName string `url:"user_name,omitempty"` Number int32 `url:"number,omitempty"` CommentType string `url:"comment_type,omitempty"` CommentImportant bool `url:"comment_important,omitempty"` Category string `url:"category,omitempty"` Offset uint32 `url:"offset,omitempty"` Limit uint32 `url:"limit,omitempty"` }
type GetSegmentTagsOpts ¶
type GetTagsOpts ¶
type GetUsersMeOpts ¶
type GetUsersMeOpts struct {
Companies bool `url:"companies,omitempty"`
}
type GetWalletTxnOpts ¶
type GetWalletTxnOpts struct { // walletable_type、walletable_idは同時に指定が必要です。 // 口座区分 (銀行口座: bank_account, クレジットカード: credit_card, 現金: wallet) WalletableType string `url:"walletable_type,omitempty"` // 口座ID WalletableID uint64 `url:"walletable_id,omitempty"` // 取引日で絞込:開始日 (yyyy-mm-dd) StartDate string `url:"start_date,omitempty"` // 取引日で絞込:終了日 (yyyy-mm-dd) EndDate string `url:"end_date,omitempty"` // 入金/出金 (入金: income, 出金: expense) EntrySide string `url:"entry_side,omitempty"` // 取得レコードのオフセット (デフォルト: 0) Offset uint32 `url:"offset,omitempty"` // 取得レコードの件数 (デフォルト: 20, 最小: 1, 最大: 100) Limit uint32 `url:"limit,omitempty"` }
type GetWalletablesOpts ¶
type Invoice ¶
type Invoice struct { // 請求書ID ID int32 `json:"id"` // 事業所ID CompanyID int32 `json:"company_id"` // 請求日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 取引先ID PartnerID int32 `json:"partner_id"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 請求書番号 InvoiceNumber string `json:"invoice_number"` // タイトル Title *string `json:"title,omitempty"` // 期日 (yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 合計金額 TotalAmount int32 `json:"total_amount"` // 合計税額 TotalVat int32 `json:"total_vat"` // 小計 SubTotal int32 `json:"sub_total"` // 売上計上日 BookingDate *string `json:"booking_date,omitempty"` // 概要 Description *string `json:"description,omitempty"` // 請求書ステータス (draft: 下書き, applying: 申請中, remanded: 差し戻し, rejected: 却下, approved: 承認済み, submitted: 送付済み, unsubmitted: 請求書の承認フローが無効の場合のみ、unsubmitted(送付待ち)の値をとります) InvoiceStatus string `json:"invoice_status"` // 入金ステータス (unsettled: 入金待ち, settled: 入金済み) PaymentStatus string `json:"payment_status"` // 入金日 (yyyy-mm-dd) PaymentDate *string `json:"payment_date,omitempty"` // Web共有日時(最新) WebPublishedAt *string `json:"web_published_at,omitempty"` // Web共有ダウンロード日時(最新) WebDownloadedAt *string `json:"web_downloaded_at,omitempty"` // Web共有取引先確認日時(最新) WebConfirmedAt *string `json:"web_confirmed_at,omitempty"` // メール送信日時(最新) MailSentAt *string `json:"mail_sent_at,omitempty"` // 郵送ステータス(unrequested: リクエスト前, preview_registered: プレビュー登録, preview_failed: プレビュー登録失敗, ordered: 注文中, order_failed: 注文失敗, printing: 印刷中, canceled: キャンセル, posted: 投函済み) PostingStatus string `json:"posting_status"` // 取引先名 PartnerName *string `json:"partner_name,omitempty"` // 請求書に表示する取引先名 PartnerDisplayName *string `json:"partner_display_name,omitempty"` // 敬称(御中、様、(空白)の3つから選択) PartnerTitle *string `json:"partner_title,omitempty"` // 取引先郵便番号 PartnerZipcode *string `json:"partner_zipcode,omitempty"` // 取引先都道府県コード(-1: 設定しない、0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄 PartnerPrefectureCode *int32 `json:"partner_prefecture_code,omitempty"` // 取引先都道府県 PartnerPrefectureName *string `json:"partner_prefecture_name,omitempty"` // 取引先市区町村・番地 PartnerAddress1 *string `json:"partner_address1,omitempty"` // 取引先建物名・部屋番号など PartnerAddress2 *string `json:"partner_address2,omitempty"` // 取引先担当者名 PartnerContactInfo *string `json:"partner_contact_info,omitempty"` // 事業所名 CompanyName string `json:"company_name"` // 郵便番号 CompanyZipcode *string `json:"company_zipcode,omitempty"` // 都道府県コード(-1: 設定しない、0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄 CompanyPrefectureCode *int32 `json:"company_prefecture_code,omitempty"` // 都道府県 CompanyPrefectureName *string `json:"company_prefecture_name,omitempty"` // 市区町村・番地 CompanyAddress1 *string `json:"company_address1,omitempty"` // 建物名・部屋番号など CompanyAddress2 *string `json:"company_address2,omitempty"` // 事業所担当者名 CompanyContactInfo *string `json:"company_contact_info,omitempty"` // 支払方法 (振込: transfer, 引き落とし: direct_debit) PaymentType string `json:"payment_type"` // 支払口座 PaymentBankInfo *string `json:"payment_bank_info,omitempty"` // メッセージ Message *string `json:"message,omitempty"` // 備考 Notes *string `json:"notes,omitempty"` // 請求書レイアウト // - default_classic - レイアウト1/クラシック (デフォルト) // - standard_classic - レイアウト2/クラシック // - envelope_classic - 封筒1/クラシック // - carried_forward_standard_classic - レイアウト3(繰越金額欄あり)/クラシック // - carried_forward_envelope_classic - 封筒2(繰越金額欄あり)/クラシック // - default_modern - レイアウト1/モダン // - standard_modern - レイアウト2/モダン // - envelope_modern - 封筒/モダン InvoiceLayout string `json:"invoice_layout"` // 請求書の消費税計算方法(inclusive: 内税, exclusive: 外税) TaxEntryMethod string `json:"tax_entry_method"` // 取引ID (invoice_statusがsubmitted, unsubmittedの時IDが表示されます) DealID *uint64 `json:"deal_id,omitempty"` // 請求内容 InvoiceContents []InvoiceContent `json:"invoice_contents"` TotalAmountPerVatRate struct { // 税率5%の税込み金額合計 Vat5 int64 `json:"vat_5"` // 税率8%の税込み金額合計 Vat8 int64 `json:"vat_8"` // 軽減税率8%の税込み金額合計 ReducedVat8 int64 `json:"reduced_vat_8"` // 税率10%の税込み金額合計 Vat10 int64 `json:"vat_10"` } `json:"total_amount_per_vat_rate"` // 関連する見積書ID(配列) // 下記で作成したものが該当します。 // // [見積書・納品書を納品書・請求書に変換する](https://support.freee.co.jp/hc/ja/articles/203318410#1-2) // [複数の見積書・納品書から合算請求書を作成する](https://support.freee.co.jp/hc/ja/articles/209076226) RelatedQuotationIDs []int32 `json:"related_quotation_ids,omitempty"` }
type InvoiceContent ¶
type InvoiceContent struct { // 請求内容ID ID uint32 `json:"id"` // 順序 Order *uint32 `json:"order,omitempty"` // 行の種類 Type string `json:"type"` // 数量 Qty json.Number `json:"qty"` // 単位 Unit *string `json:"unit,omitempty"` // 単価 UnitPrice json.Number `json:"unit_price"` // 内税/外税の判別とamountの税込み、税抜きについて // // - tax_entry_methodがexclusive (外税)の場合 // - amount: 消費税抜きの金額 // - vat: 消費税の金額 // - tax_entry_methodがinclusive (内税)の場合 // - amount: 消費税込みの金額 // - vat: 消費税の金額 Amount int64 `json:"amount"` // 消費税額 Vat int32 `json:"vat"` // 軽減税率税区分(true: 対象、false: 対象外) ReducedVat bool `json:"reduced_vat"` // 備考 Description *string `json:"description,omitempty"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 勘定科目名 AccountItemName string `json:"account_item_name"` // 税区分コード TaxCode int32 `json:"tax_code"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 品目 ItemName *string `json:"item_name,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // 部門 SectionName *string `json:"section_name,omitempty"` // メモタグID TagIDs []int32 `json:"tag_ids"` // メモタグ TagNames []string `json:"tag_names"` // セグメント1ID Segment1TagID *int64 `json:"segment_1_tag_id,omitempty"` // セグメント1 Segment1TagName *string `json:"segment_1_tag_name,omitempty"` // セグメント2ID Segment2TagID *int64 `json:"segment_2_tag_id,omitempty"` // セグメント2 Segment2TagName *string `json:"segment_2_tag_name,omitempty"` // セグメント3ID Segment3TagID *int64 `json:"segment_3_tag_id,omitempty"` // セグメント3 Segment3TagName *string `json:"segment_3_tag_name,omitempty"` }
type InvoiceCreateParams ¶
type InvoiceCreateParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 請求日 (yyyy-mm-dd) IssueDate *string `json:"issue_date,omitempty"` // 取引先ID PartnerID *int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 請求書番号 (デフォルト: 自動採番されます) InvoiceNumber *string `json:"invoice_number,omitempty"` // タイトル (デフォルト: 請求書) Title *string `json:"title,omitempty"` // 期日 (yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 売上計上日 BookingDate *string `json:"booking_date,omitempty"` // 概要 Description *string `json:"description,omitempty"` // 請求書ステータス // // - draft: 下書き (デフォルト) // - (廃止予定) issue: 発行 (送付待ち (unsubmitted) と同じです。) // - unsubmitted: 送付待ち // - submitted: 送付済み // // issue, unsubmitted, submitted は請求書承認ワークフローを利用している場合は指定できません。 InvoiceStatus *string `json:"invoice_status,omitempty"` // 請求書に表示する取引先名 PartnerDisplayName string `json:"partner_display_name"` // 敬称(御中、様、(空白)の3つから選択 PartnerTitle string `json:"partner_title"` // 取引先担当者名 PartnerContactInfo *string `json:"partner_contact_info,omitempty"` // 取引先郵便番号 (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerZipcode *string `json:"partner_zipcode,omitempty"` // 取引先都道府県コード(0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄) (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerPrefectureCode *int32 `json:"partner_prefecture_code,omitempty"` // 取引先市区町村・番地 (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerAddress1 *string `json:"partner_address1,omitempty"` // 取引先建物名・部屋番号など (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerAddress2 *string `json:"partner_address2,omitempty"` // 事業所名 (デフォルトは事業所設定情報が補完されます) CompanyName *string `json:"company_name,omitempty"` // 郵便番号 (デフォルトは事業所設定情報が補完されます) CompanyZipcode *string `json:"company_zipcode,omitempty"` // 都道府県コード(0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄) (デフォルトは事業所設定情報が補完されます) CompanyPrefectureCode *int32 `json:"company_prefecture_code,omitempty"` // 市区町村・番地 (デフォルトは事業所設定情報が補完されます) CompanyAddress1 *string `json:"company_address1,omitempty"` // 建物名・部屋番号など (デフォルトは事業所設定情報が補完されます) CompanyAddress2 *string `json:"company_address2,omitempty"` // 事業所担当者名 (デフォルトは請求書テンプレート情報が補完されます) CompanyContactInfo *string `json:"company_contact_info,omitempty"` // 支払方法 (振込: transfer, 引き落とし: direct_debit) PaymentType *string `json:"payment_type,omitempty"` // 支払口座 PaymentBankInfo *string `json:"payment_bank_info,omitempty"` // 振込専用口座の利用(利用しない: not_use(デフォルト), 利用する: use) UseVirtualTransferAccount *string `json:"use_virtual_transfer_account,omitempty"` // メッセージ (デフォルト: 下記の通りご請求申し上げます。) Message *string `json:"message,omitempty"` // 備考 Notes *string `json:"notes,omitempty"` // 請求書レイアウト // - default_classic - レイアウト1/クラシック (デフォルト) // - standard_classic - レイアウト2/クラシック // - envelope_classic - 封筒1/クラシック // - carried_forward_standard_classic - レイアウト3(繰越金額欄あり)/クラシック // - carried_forward_envelope_classic - 封筒2(繰越金額欄あり)/クラシック // - default_modern - レイアウト1/モダン // - standard_modern - レイアウト2/モダン // - envelope_modern - 封筒/モダン InvoiceLayout *string `json:"invoice_layout,omitempty"` // 請求書の消費税計算方法(inclusive: 内税表示, exclusive: 外税表示 (デフォルト)) TaxEntryMethod *string `json:"tax_entry_method,omitempty"` // 請求内容 InvoiceContents []InvoiceCreateParamsInvoiceContent `json:"invoice_contents"` }
type InvoiceCreateParamsInvoiceContent ¶
type InvoiceCreateParamsInvoiceContent struct { // 順序 Order uint32 `json:"order"` // 行の種類 // // - normal、discountを指定する場合、account_item_id,tax_codeとunit_priceが必須となります。 // - normalを指定した場合、qtyが必須となります。 Type string `json:"type"` // 数量 Qty json.Number `json:"qty"` // 単位 Unit *string `json:"unit,omitempty"` // 単価 (tax_entry_method: inclusiveの場合は税込価格、tax_entry_method: exclusiveの場合は税抜価格となります) UnitPrice json.Number `json:"unit_price"` // 消費税額 Vat *int32 `json:"vat,omitempty"` // 備考 Description *string `json:"description,omitempty"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 税区分コード TaxCode int32 `json:"tax_code"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // メモタグID TagIDs *[]int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID *int64 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID *int64 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID *int64 `json:"segment_3_tag_id,omitempty"` }
type InvoiceResponse ¶
type InvoiceResponse struct {
Invoice Invoice `json:"invoice"`
}
type InvoiceUpdateParams ¶
type InvoiceUpdateParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 請求日 (yyyy-mm-dd) IssueDate *string `json:"issue_date,omitempty"` // 取引先ID PartnerID *int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 請求書番号 (デフォルト: 自動採番されます) InvoiceNumber *string `json:"invoice_number,omitempty"` // タイトル (デフォルト: 請求書) Title *string `json:"title,omitempty"` // 期日 (yyyy-mm-dd) DueDate *string `json:"due_date,omitempty"` // 売上計上日 BookingDate *string `json:"booking_date,omitempty"` // 概要 Description *string `json:"description,omitempty"` // 請求書ステータス // // - draft: 下書き (デフォルト) // - (廃止予定) issue: 発行 (送付待ち (unsubmitted) と同じです。) // - unsubmitted: 送付待ち // - submitted: 送付済み // // issue, unsubmitted, submitted は請求書承認ワークフローを利用している場合は指定できません。 InvoiceStatus *string `json:"invoice_status,omitempty"` // 請求書に表示する取引先名 PartnerDisplayName string `json:"partner_display_name"` // 敬称(御中、様、(空白)の3つから選択) PartnerTitle string `json:"partner_title"` // 取引先担当者名 PartnerContactInfo *string `json:"partner_contact_info,omitempty"` // 取引先郵便番号 (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerZipcode *string `json:"partner_zipcode,omitempty"` // 取引先都道府県コード(0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄) (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerPrefectureCode *int32 `json:"partner_prefecture_code,omitempty"` // 取引先市区町村・番地 (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerAddress1 *string `json:"partner_address1,omitempty"` // 取引先建物名・部屋番号など (デフォルトはpartner_idもしくはpartner_codeで指定された取引先設定情報が補完されます) PartnerAddress2 *string `json:"partner_address2,omitempty"` // 事業所名 (デフォルトは事業所設定情報が補完されます) CompanyName *string `json:"company_name,omitempty"` // 郵便番号 (デフォルトは事業所設定情報が補完されます) CompanyZipcode *string `json:"company_zipcode,omitempty"` // 都道府県コード(0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄) (デフォルトは事業所設定情報が補完されます) CompanyPrefectureCode *int32 `json:"company_prefecture_code,omitempty"` // 市区町村・番地 (デフォルトは事業所設定情報が補完されます) CompanyAddress1 *string `json:"company_address1,omitempty"` // 建物名・部屋番号など (デフォルトは事業所設定情報が補完されます) CompanyAddress2 *string `json:"company_address2,omitempty"` // 事業所担当者名 (デフォルトは請求書テンプレート情報が補完されます) CompanyContactInfo *string `json:"company_contact_info,omitempty"` // 支払方法 (振込: transfer, 引き落とし: direct_debit) PaymentType *string `json:"payment_type,omitempty"` // 支払口座 PaymentBankInfo *string `json:"payment_bank_info,omitempty"` // 振込専用口座の利用(利用しない: not_use(デフォルト), 利用する: use) UseVirtualTransferAccount *string `json:"use_virtual_transfer_account,omitempty"` // メッセージ (デフォルト: 下記の通りご請求申し上げます。) Message *string `json:"message,omitempty"` // 備考 Notes *string `json:"notes,omitempty"` // 請求書レイアウト // - default_classic - レイアウト1/クラシック (デフォルト) // - standard_classic - レイアウト2/クラシック // - envelope_classic - 封筒1/クラシック // - carried_forward_standard_classic - レイアウト3(繰越金額欄あり)/クラシック // - carried_forward_envelope_classic - 封筒2(繰越金額欄あり)/クラシック // - default_modern - レイアウト1/モダン // - standard_modern - レイアウト2/モダン // - envelope_modern - 封筒/モダン InvoiceLayout *string `json:"invoice_layout,omitempty"` // 請求書の消費税計算方法(inclusive: 内税表示, exclusive: 外税表示 (デフォルト)) TaxEntryMethod *string `json:"tax_entry_method,omitempty"` // 請求内容 InvoiceContents []InvoiceUpdateParamsInvoiceContent `json:"invoice_contents"` }
type InvoiceUpdateParamsInvoiceContent ¶
type InvoiceUpdateParamsInvoiceContent struct { // 請求内容ID ID *uint32 `json:"id,omitempty"` // 順序 Order uint32 `json:"order"` // 行の種類 // // - normal、discountを指定する場合、account_item_id,tax_codeとunit_priceが必須となります。 // - normalを指定した場合、qtyが必須となります。 Type string `json:"type"` // 数量 Qty json.Number `json:"qty"` // 単位 Unit *string `json:"unit,omitempty"` // 単価 (tax_entry_method: inclusiveの場合は税込価格、tax_entry_method: exclusiveの場合は税抜価格となります) UnitPrice json.Number `json:"unit_price"` // 消費税額 Vat *int32 `json:"vat,omitempty"` // 備考 Description *string `json:"description,omitempty"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 税区分コード TaxCode int32 `json:"tax_code"` // 品目ID ItemID *int32 `json:"item_id,omitempty"` // 部門ID SectionID *int32 `json:"section_id,omitempty"` // メモタグID TagIDs *[]int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID *int64 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID *int64 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID *int64 `json:"segment_3_tag_id,omitempty"` }
type InvoicesResponse ¶
type InvoicesResponse struct {
Invoices []Invoice `json:"invoices"`
}
type Item ¶
type Item struct { // 品目ID ID int32 `json:"id"` // 事業所ID CompanyID int32 `json:"company_id"` // 品目名 (30文字以内) Name string `json:"name"` // 更新日(yyyy-mm-dd) UpdateDate string `json:"update_date"` // 品目の使用設定(true: 使用する、false: 使用しない) Available bool `json:"available"` // ショートカット1 (20文字以内) Shortcut1 *string `json:"shortcut1,omitempty"` // ショートカット2 (20文字以内) Shortcut2 *string `json:"shortcut2,omitempty"` }
type ItemParams ¶
type ItemResponse ¶
type ItemResponse struct {
Item Item `json:"item"`
}
type Logger ¶
type Logger interface {
Printf(string, ...interface{})
}
Logger generic interface for logger
type ManualJournal ¶
type ManualJournal struct { // 振替伝票ID ID uint64 `json:"id"` // 事業所ID CompanyID int32 `json:"company_id"` // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 決算整理仕訳フラグ(falseまたは未指定の場合: 日常仕訳) Adjustment bool `json:"adjustment"` // 仕訳番号 TxnNumber *string `json:"txn_number"` // 貸借行一覧(配列): 貸借合わせて100行まで登録できます。 Details []ManualJournalDetails `json:"details"` // 証憑ファイルID(ファイルボックスのファイルID)(配列) ReceiptIDs []uint64 `json:"receipt_ids"` }
type ManualJournalDetails ¶
type ManualJournalDetails struct { // 貸借行ID ID uint64 `json:"id"` // 貸借(貸方: credit, 借方: debit) EntrySide string `json:"entry_side"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 税区分コード TaxCode int32 `json:"tax_code"` // 取引先ID PartnerID *int32 `json:"partner_id"` // 取引先名 PartnerName *string `json:"partner_name"` // 取引先コード PartnerCode *string `json:"partner_code,omitempty"` // 正式名称(255文字以内) PartnerLongName *string `json:"partner_long_name"` // 品目ID ItemID *int32 `json:"item_id"` // 品目 ItemName *string `json:"item_name"` // 部門ID SectionID *int32 `json:"section_id"` // 部門 SectionName *string `json:"section_name"` TagIDs []int32 `json:"tag_ids"` TagNames []string `json:"tag_names"` // セグメント1ID Segment1TagID int32 `json:"segment_1_tag_id,omitempty"` // セグメント1ID Segment1TagName *string `json:"segment_1_tag_name,omitempty"` // セグメント2ID Segment2TagID int32 `json:"segment_2_tag_id,omitempty"` // セグメント2 Segment2TagName *string `json:"segment_2_tag_name,omitempty"` // セグメント3ID Segment3TagID int32 `json:"segment_3_tag_id,omitempty"` // セグメント3 Segment3TagName *string `json:"segment_3_tag_name,omitempty"` // 金額(税込で指定してください) Amount int32 `json:"amount"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` // 備考 Description string `json:"description"` }
type ManualJournalResponse ¶
type ManualJournalResponse struct {
ManualJournal ManualJournal `json:"manual_journal"`
}
type ManualJournalsResponse ¶
type ManualJournalsResponse struct {
ManualJournals []ManualJournal `json:"manual_journals"`
}
type Partner ¶
type Partner struct { // 取引先ID ID int32 `json:"id"` // 取引先コード Code *string `json:"code,omitempty"` // 事業所ID CompanyID int32 `json:"company_id"` // 取引先名 Name string `json:"name"` // 更新日 (yyyy-mm-dd) UpdateDate string `json:"update_date"` // 取引先の使用設定(true: 使用する、false: 使用しない) Available bool `json:"available"` // ショートカット1 (20文字以内) Shortcut1 *string `json:"shortcut1,omitempty"` // ショートカット2 (20文字以内) Shortcut2 *string `json:"shortcut2,omitempty"` // 事業所種別(null: 未設定、1: 法人、2: 個人) OrgCode *int32 `json:"org_code,omitempty"` // 地域(JP: 国内、ZZ:国外) CountryCode string `json:"country_code,omitempty"` // 正式名称(255文字以内) LongName *string `json:"long_name,omitempty"` // カナ名称(255文字以内) NameKana *string `json:"name_kana,omitempty"` // 敬称(御中、様、(空白)の3つから選択) DefaultTitle *string `json:"default_title,omitempty"` // 電話番号 Phone *string `json:"phone,omitempty"` // 担当者 氏名 ContactName *string `json:"contact_name,omitempty"` // 担当者 メールアドレス Email *string `json:"email,omitempty"` // 振込元口座ID(一括振込ファイル用):(未設定の場合は、nullです。) PayerWalletableID *int32 `json:"payer_walletable_id,omitempty"` // 振込手数料負担(一括振込ファイル用): (振込元(当方): payer, 振込先(先方): payee) TransferFeeHandlingSide string `json:"transfer_fee_handling_side,omitempty"` // AddressAttributes *PartnerAddressAttributes `json:"address_attributes,omitempty"` // DocSettingAttributes *PartnerDocSettingAttributes `json:"partner_doc_setting_attributes,omitempty"` // BankAccountAttributes *PartnerBankAccountAttributes `json:"partner_bank_account_attributes,omitempty"` }
type PartnerAddressAttributes ¶
type PartnerAddressAttributes struct { // 郵便番号 Zipcode *string `json:"zipcode,omitempty"` // 都道府県コード(0:北海道、1:青森、2:岩手、3:宮城、4:秋田、5:山形、6:福島、7:茨城、8:栃木、9:群馬、10:埼玉、11:千葉、12:東京、13:神奈川、14:新潟、15:富山、16:石川、17:福井、18:山梨、19:長野、20:岐阜、21:静岡、22:愛知、23:三重、24:滋賀、25:京都、26:大阪、27:兵庫、28:奈良、29:和歌山、30:鳥取、31:島根、32:岡山、33:広島、34:山口、35:徳島、36:香川、37:愛媛、38:高知、39:福岡、40:佐賀、41:長崎、42:熊本、43:大分、44:宮崎、45:鹿児島、46:沖縄 PrefectureCode int32 `json:"prefecture_code,omitempty"` // 市区町村・番地 StreetName1 *string `json:"street_name1,omitempty"` // 建物名・部屋番号など StreetName2 *string `json:"street_name2,omitempty"` }
type PartnerBankAccountAttributes ¶
type PartnerBankAccountAttributes struct { // 銀行名 BankName *string `json:"bank_name,omitempty"` // 銀行名(カナ) BankNameKana *string `json:"bank_name_kana,omitempty"` // 銀行番号 BankCode *string `json:"bank_code,omitempty"` // 支店名 BranchName *string `json:"branch_name,omitempty"` // 支店名(カナ) BranchKana *string `json:"branch_kana,omitempty"` // 支店番号 BranchCode *string `json:"branch_code,omitempty"` // 口座種別(ordinary:普通、checking:当座、earmarked:納税準備預金、savings:貯蓄、other:その他) AccountType *string `json:"account_type,omitempty"` // 口座番号 AccountNumber *string `json:"account_number,omitempty"` // 受取人名(カナ) AccountName *string `json:"account_name,omitempty"` // 受取人名 LongAccountName *string `json:"long_account_name,omitempty"` }
type PartnerDocSettingAttributes ¶
type PartnerDocSettingAttributes struct { // 請求書送付方法(mail:メール、posting:郵送、mail_and_posting:メールと郵送) SendingMethod *string `json:"sending_method,omitempty"` }
type PartnerResponse ¶
type PartnerResponse struct {
Partner Partner `json:"partner"`
}
type Receipt ¶
type Receipt struct { // 証憑ID ID int32 `json:"id"` // ステータス(unconfirmed:確認待ち、confirmed:確認済み、deleted:削除済み、ignored:無視) Status string `json:"status"` // メモ Description string `json:"description,omitempty"` // MIMEタイプ MimeType string `json:"mime_type"` // 発生日 IssueDate string `json:"issue_date,omitempty"` // アップロード元種別 Origin string `json:"origin"` // 作成日時(ISO8601形式) CreatedAt string `json:"created_at"` // ファイルのダウンロードURL(freeeにログインした状態でのみ閲覧可能です。) <br> <br> file_srcは廃止予定の属性になります。<br> file_srcに替わり、証憑ファイルのダウンロード APIをご利用ください。<br> 証憑ファイルのダウンロードAPIを利用することで、以下のようになります。 <ul> <li>アプリケーション利用者はfreee APIアプリケーションにログインしていれば、証憑ダウンロード毎にfreeeに改めてログインすることなくファイルが参照できるようになります。</li> </ul> FileSrc string `json:"file_src"` User UserCreatedReceipt `json:"user"` }
type ReceiptResponse ¶
type ReceiptResponse struct {
Receipt Receipt `json:"receipt"`
}
type Section ¶
type Section struct { // 部門ID ID int32 `json:"id"` // 事業所ID CompanyID int32 `json:"company_id"` // 部門名 (30文字以内) Name string `json:"name"` // 部門の使用設定(true: 使用する、false: 使用しない) Available bool `json:"available"` // ショートカット1 (20文字以内) Shortcut1 *string `json:"shortcut1,omitempty"` // ショートカット2 (20文字以内) Shortcut2 *string `json:"shortcut2,omitempty"` }
type SectionParams ¶
type SectionParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 部門名 (30文字以内) Name string `json:"name"` // 正式名称 (255文字以内) LongName *string `json:"long_name,omitempty"` // ショートカット1 (20文字以内) Shortcut1 *string `json:"shortcut1,omitempty"` // ショートカット2 (20文字以内) Shortcut2 *string `json:"shortcut2,omitempty"` // 親部門ID (ビジネスプラン以上) ParentID *int32 `json:"parent_id,omitempty"` }
type SectionResponse ¶
type SectionResponse struct {
Section Section `json:"section"`
}
type SegmentTag ¶
type SegmentTagParams ¶
type SegmentTagParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // セグメントタグ名 (30文字以内) Name string `json:"name"` // 備考 (30文字以内) Description *string `json:"description,omitempty"` // ショートカット1 (20文字以内) Shortcut1 *string `json:"shortcut1,omitempty"` // ショートカット2 (20文字以内) Shortcut2 *string `json:"shortcut2,omitempty"` }
type SegmentTagResponse ¶
type SegmentTagResponse struct {
SegmentTag SegmentTag `json:"segment_tag"`
}
type SegmentTags ¶
type SegmentTags struct {
SegmentTags []SegmentTag `json:"segment_tags"`
}
type TagResponse ¶
type TagResponse struct {
Tag Tag `json:"tag"`
}
type TaxCompanies ¶
type TaxCompanies struct {
TaxCompanies []TaxCompany `json:"taxes"`
}
type TaxCompany ¶
type TaxCompany struct { // 税区分コード Code int32 `json:"code"` // 税区分名 Name string `json:"name"` // 税区分名(日本語表示用) NameJa string `json:"name_ja"` // 税区分の表示カテゴリ(tax_5: 5%表示の税区分、tax_8: 8%表示の税区分、tax_r8: 軽減税率8%表示の税区分、tax_10: 10%表示の税区分、null: 税率未設定税区分) DisplayCategory *string `json:"display_category"` // true: 使用する、false: 使用しない Available bool `json:"available"` }
type UnauthorizedError ¶
type UnauthorizedError struct {}
type UpdateManualJournalParams ¶
type UpdateManualJournalParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 発生日 (yyyy-mm-dd) IssueDate string `json:"issue_date"` // 決算整理仕訳フラグ(falseまたは未指定の場合: 日常仕訳) Adjustment bool `json:"adjustment,omitempty"` Details []UpdateManualJournalParamsDetails `json:"details"` // 証憑ファイルID(ファイルボックスのファイルID)(配列) ReceiptIDs []uint64 `json:"receipt_ids,omitempty"` }
type UpdateManualJournalParamsDetails ¶
type UpdateManualJournalParamsDetails struct { // 貸借行ID: 既存貸借行を更新または削除する場合に指定します。IDを指定しない貸借行は、新規行として扱われ追加されます。 ID uint64 `json:"id,omitempty"` // 貸借(貸方: credit, 借方: debit) EntrySide string `json:"entry_side"` // 税区分コード TaxCode int32 `json:"tax_code"` // 勘定科目ID AccountItemID int32 `json:"account_item_id"` // 取引金額(税込で指定してください) Amount int32 `json:"amount"` // 消費税額(指定しない場合は自動で計算されます) Vat *int32 `json:"vat,omitempty"` // 取引先ID PartnerID int32 `json:"partner_id,omitempty"` // 取引先コード PartnerCode string `json:"partner_code,omitempty"` // 品目ID ItemID int32 `json:"item_id,omitempty"` // 部門ID SectionID int32 `json:"section_id,omitempty"` // メモタグID TagIDs []int32 `json:"tag_ids,omitempty"` // セグメント1ID Segment1TagID int32 `json:"segment_1_tag_id,omitempty"` // セグメント2ID Segment2TagID int32 `json:"segment_2_tag_id,omitempty"` // セグメント3ID Segment3TagID int32 `json:"segment_3_tag_id,omitempty"` // 備考 Description string `json:"description,omitempty"` }
ManualJournalUpdateParamsDetails 貸借行一覧(配列): 貸借合わせて100行まで登録できます。
type UpdatePartnerParams ¶
type UpdatePartnerParams struct { // 事業所ID CompanyID int32 `json:"company_id"` // 取引先名 (255文字以内) Name string `json:"name"` // ショートカット1 (255文字以内) Shortcut1 string `json:"shortcut1,omitempty"` // ショートカット2 (255文字以内) Shortcut2 string `json:"shortcut2,omitempty"` // 事業所種別(null: 未設定、1: 法人、2: 個人) OrgCode *int32 `json:"org_code,omitempty"` // 地域(JP: 国内、ZZ:国外) CountryCode string `json:"country_code,omitempty"` // 正式名称(255文字以内) LongName string `json:"long_name,omitempty"` // カナ名称(255文字以内) NameKana string `json:"name_kana,omitempty"` // 敬称(御中、様、(空白)の3つから選択) DefaultTitle string `json:"default_title,omitempty"` // 電話番号 Phone string `json:"phone,omitempty"` // 担当者 氏名 (255文字以内) ContactName string `json:"contact_name,omitempty"` // 担当者 メールアドレス (255文字以内) Email string `json:"email,omitempty"` // 振込元口座ID(一括振込ファイル用):(walletableのtypeが'bank_account'のidのみ指定できます。また、未設定にする場合は、nullを指定してください。) PayerWalletableID *int32 `json:"payer_walletable_id,omitempty"` // 振込手数料負担(一括振込ファイル用): (振込元(当方): payer, 振込先(先方): payee) TransferFeeHandlingSide string `json:"transfer_fee_handling_side,omitempty"` AddressAttributes CreatePartnerParamsAddressAttributes `json:"address_attributes,omitempty"` PartnerDocSettingAttributes CreatePartnerParamsPartnerDocSettingAttributes `json:"partner_doc_setting_attributes,omitempty"` PartnerBankAccountAttributes CreatePartnerParamsPartnerBankAccountAttributes `json:"partner_bank_account_attributes,omitempty"` PaymentTermAttributes CreatePartnerParamsPaymentTermAttributes `json:"payment_term_attributes,omitempty"` InvoicePaymentTermAttributes CreatePartnerParamsPaymentTermAttributes `json:"invoice_payment_term_attributes,omitempty"` }
type User ¶
type User struct { // ユーザーID ID int32 `json:"id"` // メールアドレス Email string `json:"email"` // 表示ユーザー名 DisplayName *string `json:"display_name,omitempty"` // 名 FirstName *string `json:"first_name,omitempty"` // 姓 LastName *string `json:"last_name,omitempty"` // 名(カナ) FirstNameKana *string `json:"first_name_kana,omitempty"` // 姓(カナ) LastNameKana *string `json:"last_name_kana,omitempty"` Companies []UserCompany `json:"companies,omitempty"` }
type UserCompany ¶
type UserCreatedReceipt ¶
type WalletTxn ¶
type WalletTxn struct { // 明細ID ID uint64 `json:"id"` // 事業所ID CompanyID uint32 `json:"company_id"` // 取引日(yyyy-mm-dd) Date string `json:"date"` // 取引金額 Amount int32 `json:"amount"` // 未決済金額 DueAmount int32 `json:"due_amount"` // 残高 Balance int32 `json:"balance"` // 入金/出勤(入金: income, 出勤: expense) EntrySide string `json:"entry_side"` // 口座区分 (銀行口座: bank_account, クレジットカード: credit_card, 現金: wallet) WalletableType string `json:"walletable_type"` // 口座ID WalletableID uint64 `json:"walletable_id"` // 取引内容 Description string `json:"description"` // 明細のステータス(消込待ち: 1, 消込済み: 2, 無視: 3, 消込中: 4) Status uint `json:"status"` }
type WalletTxnResponse ¶
type WalletTxnResponse struct {
WalletTxn WalletTxn `json:"wallet_txn"`
}
type WalletTxnsResponse ¶
type WalletTxnsResponse struct {
WalletTxns []WalletTxn `json:"wallet_txns"`
}
type Walletable ¶
type Walletable struct { // 口座ID ID uint64 `json:"id"` // 口座名 (255文字以内) Name string `json:"name"` // サービスID BankID uint64 `json:"bank_id"` // 口座区分 (銀行口座: bank_account, クレジットカード: credit_card, 現金: wallet) Type string `json:"type"` // 同期残高 LastBalance int64 `json:"last_balance,omitempty"` // 登録残高 WalletableBalance int64 `json:"walletable_balance,omitempty"` }
type WalletableResponse ¶
type WalletableResponse struct { Walletable Walletable `json:"walletable"` Meta Meta `json:"meta"` }
type WalletablesResponse ¶
type WalletablesResponse struct { Walletables []Walletable `json:"walletables"` Meta Meta `json:"meta"` }
Source Files
¶
Click to show internal directories.
Click to hide internal directories.