SuperAPI AI Directory

ui-theme-designer-help

Design & creation

View repository

Updated 10-16 03:52

About this skill

UI theme designer help

Context

The UI theme designer documentation is served by https://help.sap.com via a JSON HTTP API:

  • Deliverable metadata — resolves human-readable identifiers to internal IDs and provides the flat readable-URL-to-loio mapping: GET https://help.sap.com/http.svc/deliverableMetadata?product_url=btp&deliverable_url=ui-theme-designer&version=LATEST Returns data.deliverable.id (deliverable_id), data.deliverable.buildNo, and data.filePath (landing page file path).

  • Page content — fetches the HTML body of a single topic, and optionally the full hierarchical TOC: GET https://help.sap.com/http.svc/pagecontent?deliverable_id={id}&buildNo={buildNo}&file_path={loio}.html Returns data.body (HTML). With the extra param deliverableInfo=1 also returns data.deliverable.fullToc — a recursive tree of {t: title, u: filename, c: children[]} nodes covering all 80+ topics.

Procedure

Use curl -s to call all API endpoints, and jq to parse the JSON responses.

  1. Fetch deliverable metadata to obtain deliverable_id and buildNo:
    curl -s "https://help.sap.com/http.svc/deliverableMetadata?product_url=btp&deliverable_url=ui-theme-designer&version=LATEST" | jq '{id: .data.deliverable.id, buildNo: .data.deliverable.buildNo, filePath: .data.filePath}'
    
  2. Fetch the landing page with deliverableInfo=1 to get the full TOC tree:
    curl -s "https://help.sap.com/http.svc/pagecontent?deliverableInfo=1&deliverable_id={id}&buildNo={buildNo}&file_path={filePath}" | jq '.data.deliverable.fullToc'
    
  3. From the TOC, identify the topic(s) whose title best matches the user's question. If uncertain, pick 2–3 candidates.
  4. For each candidate, fetch its page content and strip HTML tags:
    curl -s "https://help.sap.com/http.svc/pagecontent?deliverable_id={id}&buildNo={buildNo}&file_path={loio}.html" | jq -r '.data.body' | sed 's/<[^>]*>//g' | tr -s '\n'
    
  5. Answer based on the retrieved content.