Embed Learn on your site with iframes

Automatic translation. View original

You can integrate the schedule preview, guest bookings, and the Learn school map on another site through <iframe>. This guide is aimed at developers implementing that integration.

Requirements and allowed domains

  • Use HTTPS and an authorized domain to host the iframe.
  • For schedules and bookings, obtain the school's public identifier: the segment that appears after /a/ in its URL. It is not a numeric ID. Check School name for (vanity ID).
  • For guest booking, the school must have guest bookings enabled.

Learn controls the sites that can embed it through the HTTP header Content-Security-Policy, directive frame-ancestors. It includes https://learn.derose.app and its subdomains *.derose.app, *.derosemethod.org and *.derosemethod.com. It can also include additional authorized domains.

A root domain is not automatically included by a rule like *.derosemethod.com. Verify the exact origin, including subdomain and port when applicable. If the site uses nested iframes, all ancestors must be allowed.

For other domains, request enabling through Contact. Include both production and testing origins. embedded=true does not authorize domains.

1. Schedule preview

Use this URL to show a generic week of recurring classes:

<iframe
  src="https://learn.derose.app/a/ESCOLA/schedule/preview?embedded=true&amp;locale=es"
  title="Horarios de la escuela"
  width="100%"
  height="800"
  loading="lazy">
</iframe>

Replace ESCOLA with the school's public identifier.

This view does not show dates or navigation between weeks. It also does not allow booking or playing classes. It shows the schedule corresponding to the simulated preview access; it does not represent booking availability for a date.

The specific URL is /schedule/preview. The previous example /horarios?preview=true uses the agenda and does not equate to this weekly grid.

Useful parameters:

Parameter Behavior
embedded=true Use the embedded presentation, without Learn's general navigation.
locale=es Select the language. It also supports pt, en, fr and it.
preview_options[user][level]=1 Simulates level 1 instead of the default level 0. It does not change the actual access of any user.

If the school provides you with a preview URL for an access predefinition, keep its parameters and add embedded=true. Use & if there is already a query string; in HTML write it as &amp;.

The grid uses a 1024 px viewport and allows zoom. Verify its readability within the available space on mobile.

2. Guest booking: guest reservations

Use the dedicated flow so a person can choose a class and submit a reservation request:

<iframe
  src="https://learn.derose.app/a/ESCOLA/guest-booking?embedded=true&amp;locale=es"
  title="Reservar una clase"
  width="100%"
  height="900"
  loading="lazy">
</iframe>

Replace ESCOLA with the same public identifier. This URL has its own reservation interface. It shows available dates and classes according to the school's configuration, and requests guest information.

The request remains pending school confirmation. If the school disables guest reservations, the page responds with HTTP 404.

When payment is required for the reservation, the form uses target="_top": the flow continues in the main window. Do not add restrictions sandbox that prevent forms, scripts, or that navigation. Test the complete flow in the browser where it will be used.

3. Schools map

The embedded DeROSE map does not require a school identifier:

<iframe
  src="https://learn.derose.app/locator/embed?for=webGlobal&amp;embedded=true&amp;locale=es"
  title="Mapa de escuelas DeROSE"
  width="100%"
  height="650"
  loading="lazy">
</iframe>

It shows the main geolocated locations of enabled DeROSE schools. Excludes schools exclusively online.

Use /locator/embed for this integration. The previous URL /locator?embedded=true&for=webGlobal is kept for compatibility. /locator without that combination corresponds to the school searcher.

You can add lat and long to indicate the center of the map, and zoom_w_location or zoom_wout_location to configure zoom with or without visitor location. If you need geolocation inside the iframe, add allow="geolocation"; this also depends on the container site's policy and the visitor's permission.

Dimensions, access, and diagnostics

The values of height the examples are starting points. Adjust them to the container and the content. height="100%" requires a container with a defined height; it does not automatically adjust the iframe to the internal document.

The browser prevents reading the DOM of an iframe from another origin. Design the container without relying on that access.

Embedded mode does not start a session nor grant permissions. Authenticated functions also depend on the session and the browser's cookie restrictions. Provide a link to open Learn directly if the flow needs to continue outside the iframe.

If the integration fails:

  1. Open the URL of the src in a tab to check the school, the path, and its parameters.
  2. If it works there but the iframe is blocked, check the console and frame-ancestors in the final response from Learn.
  3. Check the directive frame-src of your site, if it has its own CSP policy.
  4. If the general navigation appears in the preview, verify embedded=true.
  5. If guest booking returns 404, confirm the school identifier and the booking enablement.
  6. Check height, scroll, interaction, and navigation on desktop and mobile from the final domain.

Back to `Learn` API

Contact support