{"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://puranwater.com/schemas/postgres/tally_accounting/tally_ledger.schema.json","title":"tally_ledger","type":"object","properties":{"ledger_id":{"type":"string","format":"uuid","x-pg-type":"uuid"},"company_id":{"type":"string","format":"uuid","x-pg-type":"uuid"},"group_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"x-pg-type":"uuid"},"ledger_name":{"type":"string","x-pg-type":"text"},"ledger_code":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"gstin":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"pan":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"opening_balance":{"anyOf":[{"type":"number"},{"type":"null"}],"x-pg-type":"numeric"},"closing_balance":{"anyOf":[{"type":"number"},{"type":"null"}],"x-pg-type":"numeric"},"is_bill_wise":{"anyOf":[{"type":"boolean"},{"type":"null"}],"x-pg-type":"bool"},"is_cost_centre_applicable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"x-pg-type":"bool"},"quickbooks_account_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"x-pg-type":"int4"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"raw_payload":{"anyOf":[{},{"type":"null"}],"x-pg-type":"jsonb"},"created_at":{"type":"string","format":"date-time","x-pg-type":"timestamptz"},"updated_at":{"type":"string","format":"date-time","x-pg-type":"timestamptz"},"tally_guid":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"tally_alter_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"x-pg-type":"int8"},"mailing_name":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"country_of_residence":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"place_of_supply":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"gst_registration_type":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"tax_classification_name":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"hsn_code":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"},"gst_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"x-pg-type":"numeric"},"updated_datetime":{"anyOf":[{"type":"string"},{"type":"null"}],"x-pg-type":"text"}},"x-table-schema":"public","required":["company_id","ledger_name"],"x-primary-key":["ledger_id"],"x-foreign-keys":[{"column":"company_id","references_table":"tally_company","references_column":"company_id","constraint":"tally_ledger_company_id_fkey"},{"column":"group_id","references_table":"tally_group","references_column":"group_id","constraint":"tally_ledger_group_id_fkey"}]}