---
id: object/codeunit/2356
type: object
title: Codeunit 2356 "Http Response Message"
summary: Codeunit 2356 "Http Response Message" in System Application (System.RestClient). 24 public procedures. Present since at least BC23, still in BC30, changed in BC26.
tier: official
language: en
tags:
  - codeunit
  - system application
versions:
  introduced: null
  last_changed: "26"
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: e15972d8374cf86f2e3516fbc31dc4615f0f2ec9efedc80b659552dce662ed65
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/System%20Application/App/Rest%20Client/src/HttpResponseMessage.Codeunit.al
    title: src/System Application/App/Rest Client/src/HttpResponseMessage.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
object_type: codeunit
object_id: 2356
name: Http Response Message
namespace: System.RestClient
app: System Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "26"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 24
  events: 0
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 1
  called_by: 5
  implements: 0
---

# Codeunit 2356 "Http Response Message"

> Codeunit 2356 "Http Response Message" in System Application (System.RestClient). 24 public procedures. Present since at least BC23, still in BC30, changed in BC26.

System Application · System.RestClient · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/System%20Application/App/Rest%20Client/src/HttpResponseMessage.Codeunit.al) · facts from BC29

## Properties

| Property | Value |
|---|---|
| Access | Public |

## Procedures

- `Create(HttpResponseMessage: HttpResponseMessage): Codeunit "Http Response Message"`: Initializes a new instance of the HttpResponseMessage class.
- `SetIsBlockedByEnvironment(Value: Boolean)`: Sets whether the request is blocked by the environment.
- `GetIsBlockedByEnvironment(): Boolean`: Gets whether the request is blocked by the environment.
- `SetHttpStatusCode(Value: Integer)`
- `GetHttpStatusCode(): Integer`: Gets the HTTP status code of the response message.
- `SetIsSuccessStatusCode(Value: Boolean)`: Sets whether the HTTP response message has a success status code.
- `GetIsSuccessStatusCode(): Boolean`: Indicates whether the HTTP response message has a success status code.
- `SetReasonPhrase(Value: Text)`: Sets the reason phrase which typically is sent by servers together with the status code.
- `GetReasonPhrase(): Text`: Gets the reason phrase which typically is sent by servers together with the status code.
- `SetContent(Content: Codeunit "Http Content")`: Sets the HTTP content sent back by the server.
- `GetContent(): Codeunit "Http Content"`: Gets the HTTP content sent back by the server.
- `SetResponseMessage(ResponseMessage: HttpResponseMessage)`: Sets the HTTP response message.
- `GetResponseMessage(): HttpResponseMessage`: Gets the HTTP response message.
- `SetHeaders(Headers: HttpHeaders)`: Sets the HTTP headers.
- `GetHeaders(): HttpHeaders`: Gets the HTTP headers.
- `SetCookies(Cookies: Dictionary of [Text, Cookie])`: Sets the cookies in the HTTP response message.
- `GetCookies(): Dictionary of [Text, Cookie]`: Gets the cookies in the HTTP response message.
- `GetCookieNames(): List of [Text]`: Gets the names of the cookies that are set in the HTTP response message.
- `GetCookie(Name: Text): Cookie`: Gets the cookie with the given name from the HTTP response message.
- `GetCookie(Name: Text; var Cookie: Cookie): Boolean`: Gets the cookie with the given name from the HTTP response message.
- `SetErrorMessage(Value: Text)`: Sets an error message when the request failed.
- `GetErrorMessage(): Text`: Gets the error message when the request failed.
- `SetException(Exception: ErrorInfo)`: Sets the exception information when the request failed.
- `GetException(): ErrorInfo`: Gets the exception information when the request failed.

## Calls

From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an `Object::"Name"` argument. Interface dispatch and calls through events are not counted, so the list is not complete.

- [Codeunit 2357 "Http Response Message Impl."](../codeunit/2357.md) (23 calls: `Create → Create`, `GetContent → GetContent`, `GetCookie → GetCookie`, …)

## Called by

- [Codeunit 9123 "SharePoint Graph Req. Helper"](../codeunit/9123.md) (20 calls: `DownloadChunk → GetErrorMessage`, `DownloadChunk → GetHttpStatusCode`, `DownloadChunk → GetIsSuccessStatusCode`, …)
- [Codeunit 2351 "Rest Client Impl."](../codeunit/2351.md) (17 calls: `GetAsJson → GetContent`, `GetAsJson → GetException`, `GetAsJson → GetIsSuccessStatusCode`, …)
- [Codeunit 9351 "Graph Client Impl."](../codeunit/9351.md) (6 calls: `Delete → GetIsSuccessStatusCode`, `GetNextPage → GetIsSuccessStatusCode`, `GetWithPagination → GetIsSuccessStatusCode`, …)
- [Codeunit 9359 "Graph Pagination Helper"](../codeunit/9359.md) (4 calls: `ExtractNextLink → GetContent`, `ExtractNextLink → GetIsSuccessStatusCode`, `ExtractValueArray → GetContent`, …)
- [Codeunit 2360 "Http Client Handler"](../codeunit/2360.md) (1 call: `Send → Create`)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC26

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## Ask your agent

Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: `bcatlas_resolve_node(object_type: "codeunit", object_name: "Http Response Message")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
