---
title: "httpGetStatusCode"
canonical: "https://support.appfire.com/space/PSJ/15490008/httpGetStatusCode"
format: markdown
---
> Macro (aura-html)


|  |  |  |  |
| --- | --- | --- | --- |
| **Syntax** | httpGetStatusCode() | **Package** | http |
| **Alias** |  | **Pkg Usage** | statusCode() |

## Description

> Macro (excerpt)
> 
> Retrieves the HTTP status code of the latest HTTP response.

Retrieves the HTTP status code of the latest HTTP response.

## Return Type

**Number**

The value of the status code

## Example

```
number statusCode = httpGetStatusCode();
if (statusCode>= 200 && statusCode < 300) {
	print("Successful response!");
}
```

## See also

> Macro (contentbylabel)