---
title: "getPage"
canonical: "https://support.appfire.com/space/PSCONF/15304589/getPage"
format: markdown
---
> Macro (aura-html)

> Macro (table-plus)
> 
> |  |  |  |  |
> | --- | --- | --- | --- |
> | **Syntax** | getPage(spaceKey, title) | **Package** |  |
> | **Alias** |  | **Pkg Usage** |  |

## Description

> Macro (excerpt)
> 
> Retrieves a page ID by searching for space key and page title. The routine will return a -1 if the page is not found.

Retrieves a page ID by searching for space key and page title. The routine will return a -1 if the page is not found.

## Parameters

> Macro (table-plus)
> 
> | Parameter name | Type | Required | Description |
> | --- | --- | --- | --- |
> | space key | String | Yes | Key of space to search in. |
> | page title | String | Yes | Title of the page to search for. |

## Return Type

**Number**

Print Return 323827648

## Examples

### Example 1

Print Return 323827648

```javascript
number page = getPage("PSCONF", "getPage");
print("Return " + page);
```

### Example 2

Print Return -1

```javascript
number page = getPage("PSCONF", "Non-Existant Page");
print("Return " + page);
```

## See also

> Macro (contentbylabel)