---
lang: en
title: 'API docs: context.resolveinjectedarguments'
keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI
sidebar: lb4_sidebar
editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/context
permalink: /doc/en/lb4/apidocs.context.resolveinjectedarguments.html
---

<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@loopback/context](./context.md) &gt; [resolveInjectedArguments](./context.resolveinjectedarguments.md)

## resolveInjectedArguments() function

Given a function with arguments decorated with `@inject`<!-- -->, return the list of arguments resolved using the values bound in `ctx`<!-- -->.

The function returns an argument array when all dependencies were resolved synchronously, or a Promise otherwise.

**Signature:**

```typescript
export declare function resolveInjectedArguments(target: object, method: string, ctx: Context, session?: ResolutionSession, nonInjectedArgs?: any[]): ValueOrPromise<BoundValue[]>;
```

## Parameters

<table><thead><tr><th>

Parameter


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

target


</td><td>

object


</td><td>

The class for constructor injection or prototype for method injection


</td></tr>
<tr><td>

method


</td><td>

string


</td><td>

The method name. If set to '', the constructor will be used.


</td></tr>
<tr><td>

ctx


</td><td>

[Context](./context.context.md)


</td><td>

The context containing values for `@inject` resolution


</td></tr>
<tr><td>

session


</td><td>

[ResolutionSession](./context.resolutionsession.md)


</td><td>

_(Optional)_ Optional session for binding and dependency resolution


</td></tr>
<tr><td>

nonInjectedArgs


</td><td>

any\[\]


</td><td>

_(Optional)_ Optional array of args for non-injected parameters


</td></tr>
</tbody></table>
**Returns:**

[ValueOrPromise](./context.valueorpromise.md)<!-- -->&lt;[BoundValue](./context.boundvalue.md)<!-- -->\[\]&gt;


