Embedding Streamlit in external pages in Snowflake
Snowflake now allows embedding Streamlit apps in external web pages using an iframe tag, supporting viewers with or without a Snowflake account.
O que mudou
Embedding Streamlit apps in external pages is now generally available. You can render an app directly inside a customer portal or internal dashboard using a simple iframe tag.
Use cases
Imagine you built a Streamlit dashboard and need to make it available inside your company portal without requiring users to open Snowsight.
- Display apps to public viewers or users without a Snowflake account using a dedicated service user.
- Display apps to Snowflake-provisioned users while enforcing individual data privileges.
- Control which external domains are allowed to load the application inside an iframe.
How to use
Your application backend makes an HTTPS request to generate a temporary embed URL via the REST API:
POST /api/v2/databases/{database}/schemas/{schema}/streamlits/{name}:generate-embed-url
An account administrator must also grant the required privilege on the application:
GRANT USAGE ON STREAMLIT mydb.public.my_app TO ROLE embed_minter;
GRANT EMBED ON STREAMLIT mydb.public.my_app TO ROLE embed_minter;
What happens in this code:
- The command grants usage privilege on the Streamlit app to the specified role.
- The command grants the new EMBED privilege required to generate embedding URLs.
Limitations and requirements
- The feature is generally available (GA).
- Government and China regions are not supported.
- Minting an embed URL requires the new EMBED privilege in addition to USAGE.
- The external page origin domain must be pre-registered by an account administrator.
- streamlit
- embedding
- iframe
- rest api
- governance
Embedding Streamlit in Snowflake apps in external pages (General availability)
Resumo e explicação gerados por IA a partir da release note oficial. Em caso de dúvida, a documentação oficial da plataforma prevalece.
Relacionadas
- SnowflakeGA
Geração de documentos em PDF, Word e PowerPoint no Snowflake CoWork
O Snowflake CoWork agora gera arquivos PDF, Word, PowerPoint e HTML diretamente de suas análises usando a ferramenta de execução de código do Cortex Agent.
snowflake cowork · cortex agent - SnowflakePublic Preview
Cortex Agent SDK para Python e TypeScript no Snowflake
O Cortex Agent SDK permite criar aplicações que utilizam Cortex Agents e Cortex Code em Python e TypeScript.
cortex agents · python - SnowflakeAtualização
Mensagens de erro mais detalhadas na classificação de dados sensíveis
A view DATA_CLASSIFICATION_LATEST agora traz mensagens de erro específicas e códigos do Snowflake para falhas na classificação.
data governance · trust center