# InvokeMethodRequest (dapr-sdk-parent 1.10.0 API)

Package io.dapr.client.domain

## Class InvokeMethodRequest

- java.lang.Object
- - io.dapr.client.domain.InvokeMethodRequest

    public class InvokeMethodRequest
    extends Object

A request to invoke a service.

### Constructor Summary

Constructors
`InvokeMethodRequest​(String appId, String method)` Constructor for InvokeMethodRequest.

### Method Summary

All Methods Instance Methods Concrete Methods
`String` `getAppId()`
`Object` `getBody()`
`String` `getContentType()`
`HttpExtension` `getHttpExtension()`
`Map<String,​String>` `getMetadata()`
`String` `getMethod()`
`InvokeMethodRequest` `setBody​(Object body)`
`InvokeMethodRequest` `setContentType​(String contentType)`
`InvokeMethodRequest` `setHttpExtension​(HttpExtension httpExtension)`
`InvokeMethodRequest` `setMetadata​(Map<String,​String> metadata)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### InvokeMethodRequest

    public InvokeMethodRequest​(String appId,
                               String method)

Constructor for InvokeMethodRequest.

Parameters:
  `appId` - ID of the Dapr application
  `method` - Name of the method to be invoked

### Method Detail

#### getAppId

    public String getAppId()

#### getMethod

    public String getMethod()

#### getBody

    public Object getBody()

#### setBody

    public InvokeMethodRequest setBody​(Object body)

#### getHttpExtension

    public HttpExtension getHttpExtension()

#### setHttpExtension

    public InvokeMethodRequest setHttpExtension​(HttpExtension httpExtension)

#### getContentType

    public String getContentType()

#### setContentType

    public InvokeMethodRequest setContentType​(String contentType)

#### getMetadata

    public Map<String,​String> getMetadata()

#### setMetadata

    public InvokeMethodRequest setMetadata​(Map<String,​String> metadata)