> For the complete documentation index, see [llms.txt](https://paulgovan.gitbook.io/autodeskr/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://paulgovan.gitbook.io/autodeskr/viewer.md).

# Viewer

AutoDesk provides a WebGL-based viewer for rendering 2D and 3D models. To use the viewer, make sure to first follow the instructions in **Prepare a File for the Viewer** above. Then simply pass the `urn` of the file and the `token` to the `viewer3D()` function:

```
viewer3D(urn = myEncodedUrn, token = myToken)
```

![aerial](https://firebasestorage.googleapis.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-M4LNprp4nohgmYa9_j0%2Fuploads%2FZahM8Z4SbwuR3vFx3pCS%2Ffile.png?alt=media)

The viewer can also be embedded in Shiny applications, interactive R markdown documents, and other web pages thanks to the Shiny Modules framework. Here is a simple example of a Shiny app and the `viewerUI()` function:

```
ui <- function(request) {
 shiny::fluidPage(
   viewerUI("pg", myEncodedUrn, myToken)
 )
}
server <- function(input, output, session) {
}
shiny::shinyApp(ui, server)
```
