<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [ibm-cloud-sdk-core](./ibm-cloud-sdk-core.md) &gt; [VpcInstanceAuthenticator](./ibm-cloud-sdk-core.vpcinstanceauthenticator.md)

## VpcInstanceAuthenticator class

The VpcInstanceAuthenticator implements an authentication scheme in which it retrieves an "instance identity token" and exchanges that for an IAM access token using the VPC Instance Metadata Service API which is available on the local compute resource (VM). The instance identity token is similar to an IAM apikey, except that it is managed automatically by the compute resource provider (VPC).

The resulting IAM access token is then added to outbound requests in an Authorization header

Authorization: Bearer &lt;<!-- -->access-token<!-- -->&gt;

**Signature:**

```typescript
export declare class VpcInstanceAuthenticator extends TokenRequestBasedAuthenticator 
```
**Extends:** [TokenRequestBasedAuthenticator](./ibm-cloud-sdk-core.tokenrequestbasedauthenticator.md)

## Constructors

<table><thead><tr><th>

Constructor


</th><th>

Modifiers


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[(constructor)(options)](./ibm-cloud-sdk-core.vpcinstanceauthenticator._constructor_.md)


</td><td>


</td><td>

Create a new VpcInstanceAuthenticator instance.


</td></tr>
</tbody></table>

## Properties

<table><thead><tr><th>

Property


</th><th>

Modifiers


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[tokenManager](./ibm-cloud-sdk-core.vpcinstanceauthenticator.tokenmanager.md)


</td><td>

`protected`


</td><td>

[VpcInstanceTokenManager](./ibm-cloud-sdk-core.vpcinstancetokenmanager.md)


</td><td>


</td></tr>
</tbody></table>

## Methods

<table><thead><tr><th>

Method


</th><th>

Modifiers


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[authenticationType()](./ibm-cloud-sdk-core.vpcinstanceauthenticator.authenticationtype.md)


</td><td>


</td><td>

Returns the authenticator's type ('vpc').


</td></tr>
<tr><td>

[setIamProfileCrn(iamProfileCrn)](./ibm-cloud-sdk-core.vpcinstanceauthenticator.setiamprofilecrn.md)


</td><td>


</td><td>

Sets the "iamProfileCrn" value to be used when obtaining an IAM access token


</td></tr>
<tr><td>

[setIamProfileId(iamProfileId)](./ibm-cloud-sdk-core.vpcinstanceauthenticator.setiamprofileid.md)


</td><td>


</td><td>

Sets the "iamProfileId" value to be used when obtaining an IAM access token


</td></tr>
</tbody></table>
