npm package: @snokam/employees-client
Description: OpenAPI client for @snokam/employees-client
Author: OpenAPI-Generator
Latest version: 1.3.0

# @snokam/employees-client@1.3.0

A TypeScript SDK client for the employees.api.snokam.no API.

## Usage

First, install the SDK from npm.

```bash
npm install @snokam/employees-client --save
```

Next, try it out.


```ts
import {
  Configuration,
  EmployeesClient,
} from '@snokam/employees-client';
import type { GetEmployeeProtectedRequest } from '@snokam/employees-client';

async function example() {
  console.log("🚀 Testing @snokam/employees-client SDK...");
  const config = new Configuration({ 
    // To configure OAuth2 access token for authorization: Implicit implicit
    accessToken: "YOUR ACCESS TOKEN",
  });
  const api = new EmployeesClient(config);

  const body = {
    // string | The ID of the protected employee to retrieve
    id: id_example,
  } satisfies GetEmployeeProtectedRequest;

  try {
    const data = await api.getEmployeeProtected(body);
    console.log(data);
  } catch (error) {
    console.error(error);
  }
}

// Run the test
example().catch(console.error);
```


## Documentation

### API Endpoints

All URIs are relative to *https://employees.api.snokam.no*

| Class | Method | HTTP request | Description
| ----- | ------ | ------------ | -------------
*EmployeesClient* | [**getEmployeeProtected**](docs/EmployeesClient.md#getemployeeprotected) | **GET** /v1.0/protected/{id} | Gets a protected employee by ID
*EmployeesClient* | [**getEmployeePublic**](docs/EmployeesClient.md#getemployeepublic) | **GET** /v1.0/public/{slugOrId} | Gets a public employee by slug or id
*EmployeesClient* | [**getEmployeesProtected**](docs/EmployeesClient.md#getemployeesprotected) | **GET** /v1.0/protected | Gets all protected employees
*EmployeesClient* | [**getEmployeesPublic**](docs/EmployeesClient.md#getemployeespublic) | **GET** /v1.0/public | Gets all public employees
*EmployeesClient* | [**getMeProtected**](docs/EmployeesClient.md#getmeprotected) | **GET** /v1.0/protected/me | Gets the authenticated user\&#39;s protected employee data
*EmployeesClient* | [**getMyGadgetBudget**](docs/EmployeesClient.md#getmygadgetbudget) | **GET** /v1.0/protected/me/gadgetbudget | Gets the authenticated user\&#39;s gadget budget
*EmployeesClient* | [**patchMeProtected**](docs/EmployeesClient.md#patchmeprotected) | **PUT** /v1.0/protected/me | Updates the authenticated user\&#39;s protected employee data
*EmployeesClient* | [**postAnonymousFeedback**](docs/EmployeesClient.md#postanonymousfeedback) | **POST** /v1.0/feedback | Submit anonymous feedback


### Models

- [ComponentGalleryMediaInner](docs/ComponentGalleryMediaInner.md)
- [Feedback](docs/Feedback.md)
- [GadgetBudget](docs/GadgetBudget.md)
- [Geopoint](docs/Geopoint.md)
- [MuxVideoAsset](docs/MuxVideoAsset.md)
- [PatchEmployee](docs/PatchEmployee.md)
- [ProtectedEmployee](docs/ProtectedEmployee.md)
- [PublicEmployee](docs/PublicEmployee.md)
- [SanityAssetSourceData](docs/SanityAssetSourceData.md)
- [SanityEmployeeCliftonStrengthsInner](docs/SanityEmployeeCliftonStrengthsInner.md)
- [SanityEmployeeCommissionTier](docs/SanityEmployeeCommissionTier.md)
- [SanityEmployeeEquipmentInner](docs/SanityEmployeeEquipmentInner.md)
- [SanityEmployeeGroupsInner](docs/SanityEmployeeGroupsInner.md)
- [SanityEmployeeGroupsInnerLeadersInner](docs/SanityEmployeeGroupsInnerLeadersInner.md)
- [SanityEmployeeManager](docs/SanityEmployeeManager.md)
- [SanityEmployeeNextOfKinInner](docs/SanityEmployeeNextOfKinInner.md)
- [SanityEmployeeTechnologiesInner](docs/SanityEmployeeTechnologiesInner.md)
- [SanityGadgetBudgetYearlyBudgetsInner](docs/SanityGadgetBudgetYearlyBudgetsInner.md)
- [SanityGadgetBudgetYearlyBudgetsInnerEquipmentListInner](docs/SanityGadgetBudgetYearlyBudgetsInnerEquipmentListInner.md)
- [SanityImage](docs/SanityImage.md)
- [SanityImageAsset](docs/SanityImageAsset.md)
- [SanityImageCrop](docs/SanityImageCrop.md)
- [SanityImageDimensions](docs/SanityImageDimensions.md)
- [SanityImageHotspot](docs/SanityImageHotspot.md)
- [SanityImageMetadata](docs/SanityImageMetadata.md)
- [SanityImagePalette](docs/SanityImagePalette.md)
- [SanityImagePaletteSwatch](docs/SanityImagePaletteSwatch.md)
- [SanityOrderEmployee](docs/SanityOrderEmployee.md)
- [SanityPatchKeyResultOwner](docs/SanityPatchKeyResultOwner.md)
- [SanityPatchOkrIcon](docs/SanityPatchOkrIcon.md)
- [SanitySystemsInnerDescriptionInner](docs/SanitySystemsInnerDescriptionInner.md)
- [SanityTechnologyDescriptionInnerOneOfChildrenInner](docs/SanityTechnologyDescriptionInnerOneOfChildrenInner.md)
- [SanityTechnologyDescriptionInnerOneOfMarkDefsInner](docs/SanityTechnologyDescriptionInnerOneOfMarkDefsInner.md)
- [SanityTechnologyWithRelationsProjectsInnerParticipantsInnerTagsInner](docs/SanityTechnologyWithRelationsProjectsInnerParticipantsInnerTagsInner.md)
- [SanityTechnologyWithRelationsProjectsInnerTestimonialsInnerContentInnerOneOf4MediaInner](docs/SanityTechnologyWithRelationsProjectsInnerTestimonialsInnerContentInnerOneOf4MediaInner.md)
- [SanityTechnologyWithRelationsProjectsInnerTestimonialsInnerCustomerLogo](docs/SanityTechnologyWithRelationsProjectsInnerTestimonialsInnerCustomerLogo.md)
- [SanityTvCategoryDashboardsInnerBackgroundImage](docs/SanityTvCategoryDashboardsInnerBackgroundImage.md)
- [SanityTvCategoryDashboardsInnerBackgroundImageAsset](docs/SanityTvCategoryDashboardsInnerBackgroundImageAsset.md)
- [Slug](docs/Slug.md)
- [Tag](docs/Tag.md)
- [Technology](docs/Technology.md)

### Authorization


Authentication schemes defined for the API:
<a id="Implicit-implicit"></a>
#### Implicit implicit


- **Type**: OAuth
- **Flow**: implicit
- **Authorization URL**: https://login.microsoftonline.com/81a4f38d-6712-4b65-868b-c3771f9ba91e/oauth2/v2.0/authorize
- **Scopes**: 
  - `api://7ac7afa1-fda4-4679-a3b6-de4b3b0ed1cc/user_impersonation`: Default function scope

## About

This TypeScript SDK client supports the [Fetch API](https://fetch.spec.whatwg.org/)
and is automatically generated by the
[OpenAPI Generator](https://openapi-generator.tech) project:

- API version: `v1.0.0`
- Package version: `1.3.0`
- Generator version: `7.17.0`
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`

The generated npm module supports the following:

- Environments
  * Node.js
  * Webpack
  * Browserify
- Language levels
  * ES5 - you must have a Promises/A+ library installed
  * ES6
- Module systems
  * CommonJS
  * ES6 module system


## Development

### Building

To build the TypeScript source code, you need to have Node.js and npm installed.
After cloning the repository, navigate to the project directory and run:

```bash
npm install
npm run build
```

### Publishing

Once you've built the package, you can publish it to npm:

```bash
npm publish
```

## License

[]()