---
id: object/codeunit/9100
type: object
title: Codeunit 9100 "SharePoint Client"
summary: Codeunit 9100 "SharePoint Client" in System Application (System.Integration.Sharepoint). 41 public procedures, 2 events. Present since at least BC23, still in BC30, changed in BC24, BC26, BC30.
tier: official
language: en
tags:
  - codeunit
  - system application
versions:
  introduced: null
  last_changed: "30"
  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: 0d95c86dd3f0b2c28ef272e7c61e6be66f6b9421ef9edfcdaf58c15214d3410b
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/System%20Application/App/SharePoint/src/SharePointClient.Codeunit.al
    title: src/System Application/App/SharePoint/src/SharePointClient.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes:
    - change/bcapps/12064
object_type: codeunit
object_id: 9100
name: SharePoint Client
namespace: System.Integration.Sharepoint
app: System Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "24"
  - "26"
  - "30"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 43
  events: 2
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 1
  called_by: 1
  implements: 0
---

# Codeunit 9100 "SharePoint Client"

> Codeunit 9100 "SharePoint Client" in System Application (System.Integration.Sharepoint). 41 public procedures, 2 events. Present since at least BC23, still in BC30, changed in BC24, BC26, BC30.

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

## Properties

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

## Events published

- `ProcessSharePointFileMetadata(Metadata: JsonToken; var SharePointFile: Record "SharePoint File" temporary)` (integration): Process SharePointFile Metadata - Use to extract custom meta data into model record
- `ProcessSharePointListItemMetadata(Metadata: JsonToken; var SharePointListItem: Record "SharePoint List Item" temporary)` (integration): Process SharePointListItem Metadata - Use to extract custom mete data into model record

## Procedures

- `Initialize(BaseUrl: Text; Authorization: Interface "SharePoint Authorization")`: Initializes SharePoint client.
- `Initialize(BaseUrl: Text; Namespace: Text; Authorization: Interface "SharePoint Authorization")`: Initializes SharePoint client.
- `GetDiagnostics(): Interface "HTTP Diagnostics"`: Returns detailed information on last API call.
- `GetLists(var SharePointList: Record "SharePoint List"): Boolean`: Gets all lists on the given site.
- `GetListItems(ListTitle: Text; var SharePointListItem: Record "SharePoint List Item"): Boolean`: Gets all list items for the given list.
- `GetListItems(ListId: Guid; var SharePointListItem: Record "SharePoint List Item"): Boolean`: Gets all list items for the given list.
- `GetListItemAttachments(ListTitle: Text; ListItemId: Integer; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Gets all attachments for the given list item.
- `GetListItemAttachments(ListId: Guid; ListItemId: Integer; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Gets all attachments for the given list item.
- `DownloadListItemAttachmentContent(ListTitle: Text; ListItemId: Integer; FileName: Text): Boolean`: Downloads the specified attachment file to the client.
- `DownloadListItemAttachmentContent(ListId: Guid; ListItemId: Integer; FileName: Text): Boolean`: Downloads the specified attachment file to the client.
- `DownloadListItemAttachmentContent(OdataId: Text): Boolean`: Downloads the specified attachment file to the client.
- `CreateListItemAttachment(ListTitle: Text; ListItemId: Integer; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Creates the list item attachment for given item.
- `CreateListItemAttachment(ListID: Guid; ListItemId: Integer; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Creates the list item attachment for given item.
- `CreateListItemAttachment(ListTitle: Text; ListItemId: Integer; FileName: Text; var FileInStream: InStream; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Creates a list item attachment for specific list item.
- `CreateListItemAttachment(ListID: Guid; ListItemId: Integer; FileName: Text; var FileInStream: InStream; var SharePointListItemAtch: Record "SharePoint List Item Atch"): Boolean`: Creates a list item attachment for specific list item.
- `CreateList(ListTitle: Text; ListDescription: Text; var SharePointList: Record "SharePoint List"): Boolean`: Creates a new list.
- `CreateListItem(ListTitle: Text; ListItemEntityTypeFullName: Text; ListItemTitle: Text; var SharePointListItem: Record "SharePoint List Item"): Boolean`: Creates a new list item in specific list.
- `CreateListItem(ListId: Guid; ListItemEntityTypeFullName: Text; ListItemTitle: Text; var SharePointListItem: Record "SharePoint List Item"): Boolean`: Creates a new list item in specific list.
- `GetSubFoldersByServerRelativeUrl(ServerRelativeUrl: Text; var SharePointFolder: Record "SharePoint Folder"): Boolean`: Lists all subfolders in the given folder.
- `GetFolderFilesByServerRelativeUrl(ServerRelativeUrl: Text; var SharePointFile: Record "SharePoint File" temporary): Boolean`: Lists all files in the given folder.
- `GetFolderFilesByServerRelativeUrl(ServerRelativeUrl: Text; var SharePointFile: Record "SharePoint File" temporary; ListAllFields: Boolean): Boolean`: Lists all files in the given folder.
- `GetFileByServerRelativeUrl(ServerRelativeUrl: Text; var SharePointFile: Record "SharePoint File" temporary; ListAllFields: Boolean): Boolean`: Gets file data by server relative url
- `DownloadFileContent(OdataId: Text; var FileInStream: InStream): Boolean`: Downloads a file to an InStream.
- `DownloadFileContent(OdataId: Text; FileName: Text): Boolean`: Downloads a file to the client.
- `DownloadFileContent(OdataId: Text; var TempBlob: Codeunit "Temp Blob"): Boolean`: Downloads a file to a TempBlob.
- `DownloadFileContentByServerRelativeUrl(ServerRelativeUrl: Text; var FileInStream: InStream): Boolean`: Downloads a file to an InStream.
- `DownloadFileContentByServerRelativeUrl(ServerRelativeUrl: Text; FileName: Text): Boolean`: Downloads a file to the client.
- `DownloadFileContentByServerRelativeUrl(ServerRelativeUrl: Text; var TempBlob: Codeunit "Temp Blob"): Boolean`: Downloads a file to a TempBlob.
- `DeleteFile(OdataId: Text): Boolean`: Deletes a file.
- `DeleteFileByServerRelativeUrl(ServerRelativeUrl: Text): Boolean`: Deletes a file.
- `GetDocumentLibraryRootFolder(OdataID: Text; var SharePointFolder: Record "SharePoint Folder"): Boolean`: Gets root folder for the list entity (Document Library).
- `CreateFolder(ServerRelativeUrl: Text; var SharePointFolder: Record "SharePoint Folder"): Boolean`: Creates a new folder.
- `FolderExistsByServerRelativeUrl(ServerRelativeUrl: Text): Boolean`: Checks if a folder exists.
- `DeleteFolder(OdataId: Text): Boolean`: Deletes a folder.
- `DeleteFolderByServerRelativeUrl(ServerRelativeUrl: Text): Boolean`: Deletes a folder.
- `AddFileToFolder(ServerRelativeUrl: Text; var SharePointFile: Record "SharePoint File" temporary): Boolean`: Adds a file to specific folder.
- `AddFileToFolder(ServerRelativeUrl: Text; var SharePointFile: Record "SharePoint File" temporary; ListAllFields: Boolean): Boolean`: Adds a file to specific folder.
- `AddFileToFolder(ServerRelativeUrl: Text; FileName: Text; var FileInStream: InStream; var SharePointFile: Record "SharePoint File" temporary): Boolean`: Adds a file to specific folder.
- `AddFileToFolder(ServerRelativeUrl: Text; FileName: Text; var FileInStream: InStream; var SharePointFile: Record "SharePoint File" temporary; ListAllFields: Boolean): Boolean`: Adds a file to specific folder.
- `UpdateListItemMetaDataField(ListTitle: Text; ItemId: Integer; ListItemEntityTypeFullName: Text; FieldName: Text; FieldValue: Text): Boolean`: Updates metadata field for list item.
- `UpdateListItemMetaDataField(ListId: Guid; ItemId: Integer; ListItemEntityTypeFullName: Text; FieldName: Text; FieldValue: Text): Boolean`: Updates metadata field for list item.

## 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 9101 "SharePoint Client Impl."](../codeunit/9101.md) (23 calls: `AddFileToFolder → AddFileToFolder`, `CreateFolder → CreateFolder`, `CreateList → CreateList`, …)

## Called by

- [Codeunit 9103 "SharePoint List Item"](../codeunit/9103.md) (1 call: `ParseSingle → ProcessSharePointListItemMetadata`)

## Recent changes

- 2026-10-07 [#12064 Support SharePoint paths containing hash and percent characters](../../changes/bcapps/12064.md) (main, BC30, feature)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC24, BC26, BC30

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: "SharePoint Client")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
