---
title: "getRequestsTypes (Power Scripts)"
canonical: "https://support.appfire.com/space/PSJ/15483763/getRequestsTypes%20(Power%20Scripts)"
format: markdown
---
> Macro (aura-html)


## Syntax

<span style="color: #3366ff">**getRequestsTypes(portalId)**</span>

## Description

> Macro (excerpt)
> 
> Returns an array of JRequestType containing all the Request Type data for a Portal.

## Parameters

| Parameter name | Type | Required | Description |
| --- | --- | --- | --- |
| portalId | Number | Yes | Key of the selected issue |

## Return type

**JRequestType[]**

The returned number represents the id of the comment. 

## Examples

### Example 1

Use the following code to add a **public** comment to the current issue on behalf of the current user. The commentAdded event will be dispatched.

```
JRequestType[] requestTypes = getRequestsTypes(1234);
JRequestType firstRequestType = requestTypes[0];

return firstRequestType.description; 
```

## See also

> Macro (contentbylabel)