コンテンツにスキップ
IRBANK API ドキュメント
Esc
↑↓移動↵開く⌘Jプレビュー

複数条件スクリーニング

財務指標・銘柄名・業種/セクターで上場銘柄をスクリーニングする。filters は field:op:value[:unit] のカンマ区切り(AND 結合。op は gte / lte / gt / lt / eq)。指定できる条件数(filters の各条件 + sector の指定 + industry の指定)の上限は会員区分によって変わり、いずれの区分でも 20 件を超えられない。有効な指標キーと単位は GET /screening/fields。unit を書くとその単位でしきい値を解釈する(時価総額 1,000 億円は marketCap:gte:1000:hundred_million_jpy)。unit を省略した場合のしきい値と metrics[].value は GET /screening/fields の unit と同じスケール(金額は円。marketCap:gte:100000000000)で、金額指標のしきい値が 0 より大きく 100 万円未満なら旧単位 (億円) の指定とみなして 400 を返す。決算・業績予想に基づく指標(PER・ROE・配当利回り・時価総額など)を filters・sort_by に使うと、適時開示(TDnet)から 24 時間が経っていない銘柄は、その開示より前の時点の値で判定・並び替えし、metrics もその時点の値を返す(株価など他の指標も同じ時点の値になる。metrics[].as_of は検索の基準日のままで、その時点の日付にはならない)。次の検索とその銘柄では、開示より前の時点の値を使わず値なしとして扱う: as_of に過去日を指定した検索、開示より前の時点の値を残していない指標を filters・sort_by に 1 つでも使う検索(どの指標が当たるかは GET /screening/fields では区別できない)、開示より前の時点の値が残っていない銘柄。値なしの銘柄は、filters に指定すると一致せず、sort_by に指定すると末尾に並んで metrics に値が入らない。株価・出来高・テクニカル・信用残の指標だけを使う検索は対象外。

GET/screening
Authorization
AuthorizationBearer token · headerrequired

IRBANK Connect (app.irbank.net/mcp-api) で発行した API キー

Query parameters
namestring

銘柄名の部分一致

min length 1
filtersstring

指標フィルタ。field:op:value[:unit] をカンマ区切り(AND 結合)。指定できる条件数の上限は会員区分によって変わり、いずれの区分でも 20 件を超えられない。この上限は filters の各条件だけでなく、sector を指定した場合・industry を指定した場合もそれぞれ 1 件として数える。op は gte / lte / gt / lt / eq。field は GET /screening/fields の type=numeric のキー(camelCase)。unit はしきい値の単位(例 marketCap:gte:1000:hundred_million_jpy / equityRatio:gte:70:percent)で、省略時は field 自身の単位(GET /screening/fields の unit。金額は円)とみなす

min length 1
sort_bystring

ソート対象の指標キー(GET /screening/fields の type=numeric のキー)

min length 1
sort_orderstring

ソート方向(既定 desc。sort_by 指定時のみ有効)

default: "desc"
Allowed:ascdesc
sectorstring

東証17業種名のカンマ区切り(in 絞り込み)。指定すると filters の条件数上限に 1 件として数えられる

min length 1
industrystring

東証33業種名のカンマ区切り(in 絞り込み)。指定すると filters の条件数上限に 1 件として数えられる

min length 1
as_ofstring

評価基準日('now' または YYYY-MM-DD。未来日は不可。東証ライセンスにより 2005-01-01 以降のみ)

default: "now"
limitinteger
min 1 · max 100 · default: 30
cursorstring

前回レスポンスの next_cursor。cursor 以外の検索条件は前回リクエストと同一値を指定する

Responses
200

OK

securitiesScreeningSecurity[]required
Show properties
Array of ScreeningSecurity
security_codestringrequired

証券コード (4 桁)。securities 系 API の入力キー

edinet_codestringrequired
namestringrequired
metricsScreeningSecurityMetric[]required

filters / sort_by で参照した指標の値

Show properties
Array of ScreeningSecurityMetric
fieldstringrequired

指標キー

valuenumberrequired
as_ofstringrequired

検索の基準日 (YYYY-MM-DD)。適時開示 (TDnet) から 24 時間が経っていない銘柄では、決算・業績予想に基づく指標にこの日より前の時点の値が入ることがある

total_countintegerrequired

条件に合致した銘柄の総数

next_cursorstring | nullrequired

次ページ取得用の不透明 cursor。null なら最終ページ

attributionAttributionrequired
Show properties
source_labelstringrequired

出典表示ラベル(第三者に表示する際はこの表記を使う)

license_notestringrequired

出典・再配信条件の注記

processed_bystringrequired
400

パラメータまたは cursor が不正

errorobjectrequired
Show properties
codestringrequired
messagestringrequired
detailsExternalErrorDetail[]
Show properties
Array of ExternalErrorDetail
paramstringrequired
reasonstringrequired
Allowed:missingconflictinvalid_typeinvalid_formatout_of_rangeunknown_valuetoo_many_itemsinvalid
expectedstring

受理される値の要約(範囲・型・列挙値)。示せない場合は省略する

403

API キーの scope 不足 (code=forbidden)、Connect の利用許可なし (code=connect_access_required)、または規約などへの同意が済んでいない (code=legal_consent_required) のため、この API を利用できない

errorobjectrequired
Show properties
codestringrequired
messagestringrequired
detailsExternalErrorDetail[]
Show properties
Array of ExternalErrorDetail
paramstringrequired
reasonstringrequired
Allowed:missingconflictinvalid_typeinvalid_formatout_of_rangeunknown_valuetoo_many_itemsinvalid
expectedstring

受理される値の要約(範囲・型・列挙値)。示せない場合は省略する

503

一時的に応答できない。会員区分を確認できないときは code=plan_lookup_failed になる。原因は error.code で区別し、時間をおいて再試行する

errorobjectrequired
Show properties
codestringrequired
messagestringrequired
detailsExternalErrorDetail[]
Show properties
Array of ExternalErrorDetail
paramstringrequired
reasonstringrequired
Allowed:missingconflictinvalid_typeinvalid_formatout_of_rangeunknown_valuetoo_many_itemsinvalid
expectedstring

受理される値の要約(範囲・型・列挙値)。示せない場合は省略する

Try it
Server
Authorization
Parameters
Request
curl -X GET 'https://api.irbank.net/v1/screening' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json'
Response
{
  "securities": [
    {
      "security_code": "7203",
      "edinet_code": "E02144",
      "name": "トヨタ自動車",
      "metrics": [
        {
          "field": "per",
          "value": 0,
          "as_of": "string"
        }
      ]
    }
  ],
  "total_count": 0,
  "next_cursor": "string",
  "attribution": {
    "source_label": "金融庁 EDINET / TDnet",
    "license_note": "string",
    "processed_by": "IRBANK"
  }
}

このページは役に立ちましたか?