List Facts
Listing facts is done by means of a hypercube query. The easiest way to query facts is to ask for those that are in a component. Indeed, every component contains a hypercube that can be readily used as a query.
Fact tables
The results of a hypercube query are always very structured and regular (that is, same number of columns for each fact): it's like, if you consider the fact pool to be a gas of cells, you take some of its molecules, and solidify them to an ice cube.
Let us ask for all the facts in the statement of income filed by Canon.
[Public datalake] Fact table
curl -X GET "http://secxbrl.28.io/v1/_queries/public/api/facttable-for-component?aid=S1001J4B-2§ion=http://disclosure.edinet-fsa.go.jp/role/jppfs/rol_StatementOfIncome&token=c3049752-4d35-43da-82a2-f89f1b06f7a4"
Fact tables for business users
While developers will typically want to retrieve fact tables in XML or JSON format, business users will typically want it as a csv file that they can import as a spreadsheet.
So, you can just change the format to csv:
[Public datalake] Fact table as CSV
curl -X GET "http://secxbrl.28.io/v1/_queries/public/api/facttable-for-component?aid=S1001J4B-2§ion=http://disclosure.edinet-fsa.go.jp/role/jppfs/rol_StatementOfIncome&format=csv&token=c3049752-4d35-43da-82a2-f89f1b06f7a4"
However, this is not quite user-friendly, because all the report elements and values are using a computer format (QNames). Setting the labels parameter to true will make the output much fancier:
[Public datalake] Fact table as CSV with labels
curl -X GET "http://secxbrl.28.io/v1/_queries/public/api/facttable-for-component?aid=S1001J4B-2§ion=http://disclosure.edinet-fsa.go.jp/role/jppfs/rol_StatementOfIncome&format=csv&labels=true&token=c3049752-4d35-43da-82a2-f89f1b06f7a4"
You can also use the language parameter to request a different language (if available in the repository), for example, to get the same output in Japanese:
[Public datalake] Fact table as CSV with Japanese labels
curl -X GET "http://secxbrl.28.io/v1/_queries/public/api/facttable-for-component?aid=S1001J4B-2§ion=http://disclosure.edinet-fsa.go.jp/role/jppfs/rol_StatementOfIncome&format=csv&labels=true&language=ja&token=c3049752-4d35-43da-82a2-f89f1b06f7a4"
For business users using BI tools such as Tableau, the Atom (OData) format is also available.
[Public datalake] Fact table as CSV with Japanese labels
curl -X GET "http://secxbrl.28.io/v1/_queries/public/api/facttable-for-component?aid=S1001J4B-2§ion=http://disclosure.edinet-fsa.go.jp/role/jppfs/rol_StatementOfIncome&format=atom-xml&labels=true&language=ja&token=c3049752-4d35-43da-82a2-f89f1b06f7a4"