Discover/cses.fi API
live

cses.fi APIcses.fi

Access CSES problem lists, full problem statements, category filters, courses, and contests via a structured JSON API with 5 endpoints.

Endpoints
5
Updated
14d ago
Try it

No input parameters required.

api.parse.bot/scraper/1b9e55e4-6851-41ea-ba8a-1383ad8800c0/<endpoint>
Ready to send
Fill in the parameters and hit sign in to send to see live response data here.
Use it in your codegrab a free API key at signup
curl -X GET 'https://api.parse.bot/scraper/1b9e55e4-6851-41ea-ba8a-1383ad8800c0/get_problem_set_list' \
  -H 'X-API-Key: $PARSE_API_KEY'
All endpoints · 5 totalclick to expand

Returns all problems in the CSES Problem Set grouped by category, including names, task IDs, acceptance stats, optimal technique summaries, and URLs.

Input

No input parameters required.

Response
{
  "type": "object",
  "fields": {
    "categories": "array of category objects, each containing category name and problems array"
  },
  "sample": {
    "data": {
      "categories": [
        {
          "category": "Introductory Problems",
          "problems": [
            {
              "url": "https://cses.fi/problemset/task/1068",
              "name": "Weird Algorithm",
              "stats": "163712 / 171218",
              "task_id": "1068",
              "technique": "Simulation (Collatz conjecture)"
            }
          ]
        }
      ]
    },
    "status": "success"
  }
}

About the cses.fi API

The CSES API gives programmatic access to the cses.fi competitive programming platform across 5 endpoints, returning problem lists grouped by category, full problem statements with time and memory limits, and catalogs of courses and contests. The get_problem_detail endpoint alone returns 10 structured fields per problem, including description text, input/output format, constraints, and example cases.

Problem Set Browsing

The get_problem_set_list endpoint returns every problem on the CSES Problem Set organized into category objects. Each category contains an array of problems with their names, numeric task_id values, acceptance statistics, suggested technique labels, and direct URLs. This gives a full structural snapshot of the problem set in one call — no parameters required.

To drill down to a specific topic, get_problems_by_category accepts a category string (e.g. 'Dynamic Programming', 'Graph Algorithms', 'Sorting and Searching') and returns matching problems with the same per-problem fields: name, task_id, stats, technique, and url.

Problem Detail

get_problem_detail takes a single required parameter — task_id — and returns the complete problem statement. Response fields include title, description, input_format, output_format, constraints, time_limit (e.g. '1.00 s'), memory_limit (e.g. '512 MB'), a technique hint, and an examples array with input / output pairs. This is enough to render a full problem view or feed it into automated analysis.

Courses and Contests

get_courses_list and get_contests_list each return flat arrays of objects with name, description, and url. These cover the educational courses hosted on CSES alongside any active or past contests, making it straightforward to enumerate the full learning and competition offering alongside the problem data.

Common use cases
  • Build a personal study tracker that maps CSES problems by category using get_problems_by_category and tracks which technique labels appear most often.
  • Render full problem statements in a custom offline reader using the description, input_format, output_format, and examples fields from get_problem_detail.
  • Generate flashcard decks for competitive programming techniques by extracting the technique field across all problems returned by get_problem_set_list.
  • Create a difficulty or acceptance-rate leaderboard by aggregating the stats field from problems across all categories.
  • Enumerate CSES courses and contests for a competitive programming resource directory using get_courses_list and get_contests_list.
  • Automate problem recommendation by filtering categories and cross-referencing technique hints against a user's solved-problem history.
  • Index the full CSES problem corpus into a search engine using title, description, and constraints from bulk get_problem_detail calls.
Pricing & limitsSee full pricing →
TierPriceCredits/monthRate limit
Free$0/mo1005 req/min
Hobby$30/mo1,00020 req/min
Developer$100/mo5,000250 req/min

One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.

Frequently asked questions
Does cses.fi have an official developer API?+
No. cses.fi does not publish an official public API or developer documentation for programmatic access to its problem set or contest data.
What does `get_problem_detail` return beyond the problem text?+
get_problem_detail returns 10 fields: title, task_id, description, input_format, output_format, constraints, time_limit, memory_limit, technique, and an examples array. Each object in examples contains an input string and an output string matching the sample cases shown on the problem page.
Does the API return user submission history or solution code?+
Not currently. The API covers problem metadata, full problem statements, courses, and contests. User accounts, submission records, accepted solutions, and personal statistics are not exposed. You can fork this API on Parse and revise it to add an endpoint targeting submission or leaderboard data if that access is available without authentication.
Are editorial or solution hints included in the problem detail response?+
Not currently. The get_problem_detail response includes a technique field with a short label for the suggested approach, but full editorial text and solution explanations are not part of the response. You can fork this API on Parse and revise it to add an editorial endpoint if that content is accessible on cses.fi.
How specific are the category names accepted by `get_problems_by_category`?+
The category parameter must match a category name as it appears in the CSES Problem Set — for example, 'Introductory Problems', 'Sorting and Searching', or 'Dynamic Programming'. You can retrieve the full list of valid category names by calling get_problem_set_list first and extracting the category name field from each returned category object.
Page content last updated . Spec covers 5 endpoints from cses.fi.
Related APIs in EducationSee all →
arxiv.org API
Search and discover academic research papers on arXiv using keywords, authors, titles, categories, and dates, then access detailed metadata for any paper. Browse the complete arXiv category taxonomy to explore research across different scientific disciplines.
maxpreps.com API
Access high school sports data from MaxPreps. Search for schools, retrieve team rosters and schedules, look up athlete profiles, and browse national or state rankings across all sports.
athletic.net API
Search and analyze cross country and track & field performance data across the US, including athlete profiles, meet results, team rosters, and rankings. Access comprehensive meet information, historical records, and state-level competition data to track athlete progress and discover top performers.
allaboutcircuits.com API
Access educational electronics content from All About Circuits, including technical articles, circuit diagrams, textbook volumes, and forum discussions organized by category. Search and browse the latest resources, view detailed articles, explore engineering tools, and find answers across their community forums.
illinoisreportcard.com API
Search and analyze comprehensive performance data for Illinois public schools, districts, and the state, including academic achievements in ELA, math, and science, student demographics, teacher and administrator information, school finances, and environmental conditions. Compare schools side-by-side, track growth metrics, and access accountability ratings and school highlights to make informed decisions about education quality.
noor-book.com API
Search and discover books across 1,800+ categories in the Noor Book library, retrieving detailed information about titles, authors, biographies, and book metadata. Access comprehensive author profiles and browse one of the largest Arabic and English digital book collections with over 289,000 authors.
quizbowlpackets.com API
Search and browse thousands of quizbowl question sets across all competition levels, then access detailed metadata like difficulty, subjects, and download links for each packet. Find the perfect practice materials for High School, Collegiate, Middle School, or Pop Culture quizbowl competitions.
amberstudent.com API
Search student accommodation listings across popular cities and access comprehensive property information including room types, pricing trends, and tenant reviews. Get detailed insights into student housing options to compare amenities, prices, and community feedback all in one place.