> For the complete documentation index, see [llms.txt](https://xmlking.gitbook.io/micro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://xmlking.gitbook.io/micro/develop/modules/services/greeter.md).

# Greeter

This is the Greeter service

## Configuration

* FQDN: mkit.service.greeter
* Type: service
* Alias: greeter

## Usage

Build the binary

```bash
make build TARGET=greeter TYPE=service
# then run with custom env
CONFIGOR_ENV_PREFIX=APP APP_FEATURES_TLS_ENABLED=true ./build/greeter-service
```

Run the service

```bash
make run-greeter
make run-greeter ARGS="--server_address=:8081"
# or
go run service/greeter/main.go service/greeter/plugin.go
```

Build a docker image

```bash
make docker TARGET=greeter TYPE=service VERSION=v0.1.1
```

Test the service

```bash
# start greeter service first
make run-greeter

# test with grpc cli
grpcurl -plaintext -proto service/greeter/proto/greeter/greeter.proto list
grpcurl -plaintext -proto service/greeter/proto/greeter/greeter.proto describe
grpcurl -plaintext -proto service/greeter/proto/greeter/greeter.proto -d '{"name": "sumo"}' localhost:8081  mkit.service.greeter.v1.GreeterService/Hello
# testing via micro-cli
micro call mkit.service.greeter GreeterService.Hello  '{"name": "John"}'

# start REST gateway
micro api --enable_rpc=true

# testing via rest proxy
curl --request POST \
--url http://localhost:8080/rpc \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '{"service": "mkit.service.greeter", "method": "GreeterService.Hello","request": {"name": "sumo"}}'
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://xmlking.gitbook.io/micro/develop/modules/services/greeter.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
