# @microsoft/microsoft-graph-types-beta

> Beta version of Typings for Microsoft Graph objects

Latest version **0.44.0-preview** (published 2025-09-30) · 0 weekly downloads

## Install

```sh
npm install @microsoft/microsoft-graph-types-beta
pnpm add @microsoft/microsoft-graph-types-beta
yarn add @microsoft/microsoft-graph-types-beta
bun add @microsoft/microsoft-graph-types-beta
```

## Health

**Score 55/100 (C)** — status: stable.

Positive: has types; no vulnerabilities; high maintenance score.

Warnings: low downloads; no esm support; pre 1.0.

## Facts

| | |
|---|---|
| Version | 0.44.0-preview |
| Published | 2025-09-30 |
| First published | 2021-03-03 |
| Weekly downloads | 0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 4.1 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 7 |
| Maintainers | nikithauc, microsoftgraph, microsoft1es |

## Links

- npm: https://www.npmjs.com/package/@microsoft/microsoft-graph-types-beta
- Repository: https://github.com/microsoftgraph/msgraph-beta-typescript-typings
- Homepage: https://github.com/microsoftgraph/msgraph-beta-typescript-typings#readme
- Issues: https://github.com/microsoftgraph/msgraph-beta-typescript-typings/issues
- npm.io page: https://npm.io/package/@microsoft/microsoft-graph-types-beta

## Recent versions

- 0.44.0-preview (latest) — 2025-09-30
- 0.43.0-preview — 2024-09-04
- 0.42.0-preview — 2023-11-21
- 0.40.0-preview — 2023-07-26
- 0.37.0-preview — 2023-06-29
- 0.36.0-preview — 2023-06-12
- 0.35.0-preview — 2023-05-23
- 0.34.0-preview — 2023-05-17
- 0.33.0-preview — 2023-05-10
- 0.32.0-preview — 2023-05-03
- 0.31.0-preview — 2023-04-26
- 0.30.0-preview — 2023-04-18
- 0.29.0-preview — 2022-05-03
- 0.28.0-preview — 2022-04-12
- 0.27.0-preview — 2022-04-12
- … 25 more at https://npm.io/package/@microsoft/microsoft-graph-types-beta/versions

## README

[![npm version badge](https://img.shields.io/npm/v/@microsoft/microsoft-graph-types-beta?color=blue)](https://www.npmjs.com/package/@microsoft/microsoft-graph-types-beta)

# Microsoft Graph TypeScript Types Beta
The Microsoft Graph TypeScript definitions enable editors to provide intellisense on Microsoft Graph /beta endpoint objects including users, messages, and groups.

> **_NOTE:_**  APIs under the /beta version in Microsoft Graph are subject to change.

## Installation

We recommend including the .d.ts file by downloading this package through [npm](https://www.npmjs.com/).

```bash

# Install types and save in package.json as a development dependency
npm install @microsoft/microsoft-graph-types-beta --save-dev

```

## Examples
The following examples assume that you have a valid access token. The following example uses [isomorphic-fetch](https://www.npmjs.com/package/isomorphic-fetch) and  [Microsoft Graph JavaScript client library](https://github.com/microsoftgraph/msgraph-sdk-javascript) -

```typescript
import { User } from "@microsoft/microsoft-graph-types-beta";

import { Client } from "@microsoft/microsoft-graph-client";

import 'isomorphic-fetch';

const client = Client.initWithMiddleware({
	defaultVersion: 'beta',
	...
});

const response = await client.api("/me").get();
const user = response as User;
```

### Example of creating an object
```typescript
// Create the message object

// Note that all the properties must follow the interface definitions.
// For example, this will not compile if you try to type "xml" instead of "html" for contentType.

let mail:MicrosoftGraphBeta.Message = {
    subject: "Microsoft Graph TypeScript Sample",
    toRecipients: [{
        emailAddress: {
            address: "microsoftgraph@example.com"
        }
    }],
    body: {
        content: "<h1>Microsoft Graph TypeScript Sample</h1>Try modifying the sample",
        contentType: "html"
    }
}
```

## Example of using v1 types and beta types together
```json
  "devDependencies": {
    // import published v1.0 types with a version from NPM
    "@microsoft/microsoft-graph-types": "^0.4.0",
    // import beta types with a version from NPM
    "@microsoft/microsoft-graph-types-beta": "^0.1.0-preview"
  }
}
```

```typescript
import * as MicrosoftGraph from "@microsoft/microsoft-graph-types"

import * as MicrosoftGraphBeta from "@microsoft/microsoft-graph-types-beta"

const v1User: MicrosoftGraph.User = {
	givenName: "V1 User"
}

const betaUser: MicrosoftGraphBeta.User = {
	givenName: "Beta User"
}

```

## Supported editors
Any TypeScript project can consume these types when using at least TypeScript 2.0.  We've tested including the types as a dependency in the following editors.
* Visual Studio Code
* WebStorm
* Atom with the [atom-typescript](https://atom.io/packages/atom-typescript) plugin

## Questions and comments

We'd love to get your feedback about the TypeScript definitions project. You can send your questions and suggestions to us in the [Issues](https://github.com/microsoftgraph/msgraph-beta-typescript-typings/issues) section of this repository.

## Contributing
Please see the [contributing guidelines](CONTRIBUTING.md).

## Additional resources

* [Microsoft Graph](https://graph.microsoft.io)
* [Office Dev Center](http://dev.office.com/)
* [Microsoft Graph JavaScript Client Library](https://github.com/microsoftgraph/msgraph-sdk-javascript)
* [Use the Microsoft Graph SDKs with the beta API](https://docs.microsoft.com/en-us/graph/sdks/use-beta?tabs=CS)

## Copyright
Copyright (c) 2021 Microsoft. All rights reserved.

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.

---
_Source: https://npm.io/package/@microsoft/microsoft-graph-types-beta · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
