---
id: object/table/1140
type: object
title: Table 1140 "OAuth 2.0 Setup"
summary: Table 1140 "OAuth 2.0 Setup" in Base Application (System.Security.Authentication). 25 fields, 4 public procedures, 5 events. Present since at least BC23, still in BC30, changed in BC24, BC27.
tier: official
language: en
tags:
  - table
  - base application
versions:
  introduced: null
  last_changed: "27"
  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: 8c52bfaa4373a08af7200a1bf97662094abbfa0955ce0035c261b4fce4373107
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/System/OAuth/OAuth20Setup.Table.al
    title: src/Layers/W1/BaseApp/System/OAuth/OAuth20Setup.Table.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
object_type: table
object_id: 1140
name: OAuth 2.0 Setup
namespace: System.Security.Authentication
app: Base Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "24"
  - "27"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 25
  procedures: 10
  events: 5
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 1
  extended_by: 0
  event_subscribers: 0
  calls: 0
  called_by: 0
  implements: 0
---

# Table 1140 "OAuth 2.0 Setup"

> Table 1140 "OAuth 2.0 Setup" in Base Application (System.Security.Authentication). 25 fields, 4 public procedures, 5 events. Present since at least BC23, still in BC30, changed in BC24, BC27.

Base Application · System.Security.Authentication · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/System/OAuth/OAuth20Setup.Table.al) · facts from BC29

## Properties

| Property | Value |
|---|---|
| Caption | OAuth 2.0 Setup |
| DataClassification | CustomerContent |

## Fields

Explanation: the field's ToolTip in the code; without one, the ToolTip of a page control bound to the field (marked via the page); without that, its Caption (marked caption) when that differs from the name.

| No. | Name | Type | Explanation | Notes |
|---|---|---|---|---|
| 1 | Code | Code[20] | — | NotBlank |
| 2 | Description | Text[250] | Specifies the description. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 3 | Service URL | Text[250] | Specifies the service URL. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 4 | Redirect URL | Text[250] | Specifies the redirect URL. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 5 | Client ID | Guid | — | DataClassification EndUserIdentifiableInformation |
| 6 | Client Secret | Guid | — | DataClassification EndUserIdentifiableInformation |
| 7 | Access Token | Guid | — | DataClassification EndUserIdentifiableInformation |
| 8 | Refresh Token | Guid | — | DataClassification EndUserIdentifiableInformation |
| 9 | Authorization URL Path | Text[250] | Specifies the authorization URL path. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 10 | Access Token URL Path | Text[250] | Specifies the access token URL path. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 11 | Refresh Token URL Path | Text[250] | Specifies the refresh token URL path. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 12 | Scope | Text[250] | Specifies the scope. <small>via [Page 1140 "OAuth 2.0 Setup"](../page/1140.md)</small> |  |
| 13 | Authorization Response Type | Text[250] | — |  |
| 14 | Status | Option | — | OptionCaption: ,Enabled,Disabled,Connected,Error |
| 15 | Token DataScope | Option | — | OptionCaption: Module,User,Company,UserAndCompany |
| 16 | Activity Log ID | Integer | — |  |
| 17 | Daily Limit | Integer | — | not editable |
| 18 | Daily Count | Integer | — | not editable |
| 19 | Latest Datetime | DateTime | — | not editable |
| 20 | Access Token Due DateTime | DateTime | — | not editable |
| 21 | Feature GUID | Guid | — | not editable |
| 22 | User ID | Code[50] | — | TableRelation User."User Name"; DataClassification EndUserIdentifiableInformation |
| 50 | Code Challenge Method | Enum "OAuth 2.0 Code Challenge" | — | enum [Enum 1140 "OAuth 2.0 Code Challenge"](../enum/1140.md) |
| 51 | Code Verifier | Guid | — |  |
| 52 | Use Nonce | Boolean | — |  |

## Keys

- Key1: Code (clustered)

## Events published

- `OnAfterRequestAccessToken(OAuth20Setup: Record "OAuth 2.0 Setup"; Result: Boolean; var MessageText: Text)` (integration)
- `OnBeforeRequestAuthoizationCode(OAuth20Setup: Record "OAuth 2.0 Setup"; var Processed: Boolean)` (integration)
- `OnBeforeRefreshAccessToken(var OAuth20Setup: Record "OAuth 2.0 Setup"; var Result: Boolean; var MessageText: Text; var Processed: Boolean)` (integration)
- `OnBeforeRequestAccessToken(var OAuth20Setup: Record "OAuth 2.0 Setup"; AuthorizationCode: Text; var Result: Boolean; var MessageText: Text; var Processed: Boolean)` (integration)
- `OnBeforeInvokeRequest(var OAuth20Setup: Record "OAuth 2.0 Setup"; RequestJSON: Text; var ResponseJSON: Text; var HttpError: Text; var Result: Boolean; var Processed: Boolean; RetryOnCredentialsFailure: Boolean)` (integration)

## Procedures

- `GetTokenDataScope(): DataScope`
- `FindSetOAuth20SetupByFeature(FeatureGUID: Guid): Boolean`
- `FindFirstOAuth20SetupByFeatureAndCurrUser(FeatureGUID: Guid): Boolean`
- `FindFirstOAuth20SetupByFeatureAndUser(FeatureGUID: Guid; OAuthUserID: Code[50]): Boolean`

Plus 1 local procedures.

## Triggers

OnDelete

## Pages and codeunits on this table

- [Page 1140 "OAuth 2.0 Setup"](../page/1140.md) (source table)

## Across versions

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

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). 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: "table", object_name: "OAuth 2.0 Setup")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
