Get started with profanity filter Extend Override app template
This is available in AGS Private Cloud only at the moment.
Overview
AccelByte Gaming Services (AGS) allows you to implement custom logic for profanity filtering.
This article walks you through the process of setting up custom profanity filter logic using the Extend Override app template as an example.
Prerequisites
- C#
- Go
- Java
- Python
-
Windows 11 WSL2/Linux Ubuntu 22.04 or macOS 14+ with the following tools installed:
a. Bash
-
On Windows WSL2 or Linux Ubuntu:
bash --version
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
... -
On macOS:
bash --version
GNU bash, version 3.2.57(1)-release (arm64-apple-darwin23)
...
b. Make
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install make.make --version
GNU Make 4.3
... -
On macOS:
make --version
GNU Make 3.81
...
c. Docker (Docker Desktop 4.30+/Docker Engine v23.0+)
-
On Linux Ubuntu:
- To install from the Ubuntu repository, run
sudo apt update && sudo apt install docker.io docker-buildx docker-compose-v2. - Add your user to the
dockergroup:sudo usermod -aG docker $USER. - Log out and log back in to allow the changes to take effect.
- To install from the Ubuntu repository, run
-
On Windows or macOS:
Follow Docker's documentation on installing the Docker Desktop on Windows or macOS.
docker version
...
Server: Docker Desktop
Engine:
Version: 24.0.5
...
d. .NET 8 SDK
-
On Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt-get update && sudo apt-get install -y dotnet-sdk-8.0. -
On Windows or macOS:
Follow Microsoft's documentation for installing .NET on Windows or on macOS.
dotnet --version
8.0.119
e. Postman
- Use the available binary from Postman.
- Use the available binary from extend-helper-cli.
g. Local tunnel service that has TCP forwarding capability, such as:
-
Need registration for free tier. Please refer to ngrok documentation for a quick start.
-
Free to try without registration. Please refer to pinggy documentation for a quick start.
-
-
Windows 11 WSL2/Linux Ubuntu 22.04 or macOS 14+ with the following tools installed:
a. Bash
-
On Windows WSL2 or Linux Ubuntu:
bash --version
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
... -
On macOS:
bash --version
GNU bash, version 3.2.57(1)-release (arm64-apple-darwin23)
...
b. Make
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install make.make --version
GNU Make 4.3
... -
On macOS:
make --version
GNU Make 3.81
...
c. Docker (Docker Desktop 4.30+/Docker Engine v23.0+)
-
On Linux Ubuntu:
- To install from the Ubuntu repository, run
sudo apt update && sudo apt install docker.io docker-buildx docker-compose-v2. - Add your user to the
dockergroup:sudo usermod -aG docker $USER. - Log out and log back in to allow the changes to take effect.
- To install from the Ubuntu repository, run
-
On Windows or macOS:
Follow Docker's documentation on installing the Docker Desktop on Windows or macOS.
docker version
...
Server: Docker Desktop
Engine:
Version: 24.0.5
...
d. Go v1.24
-
Follow Go's installation guide.
go version
go version go1.24.0 ...
e. Postman
- Use the available binary from Postman.
- Use the available binary from extend-helper-cli.
g. Local tunnel service that has TCP forwarding capability, such as:
-
Need registration for free tier. Please refer to ngrok documentation for a quick start.
-
Free to try without registration. Please refer to pinggy documentation for a quick start.
-
-
Windows 11 WSL2/Linux Ubuntu 22.04 or macOS 14+ with the following tools installed:
a. Bash
-
On Windows WSL2 or Linux Ubuntu:
bash --version
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
... -
On macOS:
bash --version
GNU bash, version 3.2.57(1)-release (arm64-apple-darwin23)
...
b. Make
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install make.make --version
GNU Make 4.3
... -
On macOS:
make --version
GNU Make 3.81
...
c. Docker (Docker Desktop 4.30+/Docker Engine v23.0+)
-
On Linux Ubuntu:
- To install from the Ubuntu repository, run
sudo apt update && sudo apt install docker.io docker-buildx docker-compose-v2. - Add your user to the
dockergroup:sudo usermod -aG docker $USER. - Log out and log back in to allow the changes to take effect.
- To install from the Ubuntu repository, run
-
On Windows or macOS:
Follow Docker's documentation on installing the Docker Desktop on Windows or macOS.
docker version
...
Server: Docker Desktop
Engine:
Version: 24.0.5
...
d. JDK 17
-
On Linux Ubuntu:
To install from the Ubuntu repository, run:
sudo apt update && sudo apt install openjdk-17-jdk. -
On Windows or macOS:
Follow Microsoft's documentation for installing the Microsoft Build for OpenJDK.
java --version
openjdk 17.0.10 2024-01-16
...
e. Postman
- Use the available binary from Postman.
- Use the available binary from extend-helper-cli.
g. Local tunnel service that has TCP forwarding capability, such as:
-
Need registration for free tier. Please refer to ngrok documentation for a quick start.
-
Free to try without registration. Please refer to pinggy documentation for a quick start.
-
-
Windows 11 WSL2/Linux Ubuntu 22.04 or macOS 14+ with the following tools installed:
a. Bash
-
On Windows WSL2 or Linux Ubuntu:
bash --version
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
... -
On macOS:
bash --version
GNU bash, version 3.2.57(1)-release (arm64-apple-darwin23)
...
b. Make
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install make.make --version
GNU Make 4.3
... -
On macOS:
make --version
GNU Make 3.81
...
c. Docker (Docker Desktop 4.30+/Docker Engine v23.0+)
-
On Linux Ubuntu:
- To install from the Ubuntu repository, run
sudo apt update && sudo apt install docker.io docker-buildx docker-compose-v2. - Add your user to the
dockergroup:sudo usermod -aG docker $USER. - Log out and log back in to allow the changes to take effect.
- To install from the Ubuntu repository, run
-
On Windows or macOS:
Follow Docker's documentation on installing the Docker Desktop on Windows or macOS.
docker version
...
Server: Docker Desktop
Engine:
Version: 24.0.5
...
d. Python 3.10
-
On Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install python3 python3-venv. -
On Windows or macOS:
Use the available installer here.
python3 --version
Python 3.10.12
e. Curl
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install curl.curl --version
curl 7.81.0 (x86_64-pc-linux-gnu)
... -
On macOS:
curl --version
curl 8.4.0 (x86_64-apple-darwin23.0) ...
...
f. Jq
-
On Windows WSL2 or Linux Ubuntu:
To install from the Ubuntu repository, run
sudo apt update && sudo apt install jq.jq --version
jq-1.6
... -
On macOS:
To install using Homebrew, run
brew install jq.jq --version
jq-1.7.1
g. Postman
- Use the available binary from Postman.
- Use the available binary from extend-helper-cli.
i. Local tunnel service that has TCP forwarding capability, such as:
-
Need registration for free tier. Please refer to ngrok documentation for a quick start.
-
Free to try without registration. Please refer to pinggy documentation for a quick start.
tipSee also Python Development Environment guide.
-
- Access to the AGS Admin Portal environment.
- Base URL:
<your environment's domain URL>- Example for AGS Private Cloud customer:
https://dev.customer.accelbyte.io
- Example for AGS Private Cloud customer:
- Create a game namespace if you don't have one yet. Take note of the namespace ID.
- Create an OAuth Client with
confidentialclient type. Keep theClient IDandClient Secret.
- Base URL:
Clone the app template
- C#
- Go
- Java
- Python
git clone https://github.com/AccelByte/profanity-filter-grpc-plugin-server-csharp.git
git clone https://github.com/AccelByte/profanity-filter-grpc-plugin-server-go.git
git clone https://github.com/AccelByte/profanity-filter-grpc-plugin-server-java.git
git clone https://github.com/AccelByte/profanity-filter-grpc-plugin-server-python.git
Set up, run, and test an Extend app
This section covers how to set up, build, run, and then test an Extend app.
Set up the Extend app
To be able to run this app, follow these setup steps:
-
Create a docker compose
.envfile by copying the content of the.env.templatefile.noteThe host OS environment variables have higher precedence compared to the
.envfile variables. If the variables in the.envfile do not seem to take effect properly, check if there are host OS environment variables with the same name. For more details, refer to Docker's documentation about the docker compose environment variables precedence. -
Fill in the required environment variables in the
.envfile as shown below:.AB_BASE_URL=https://test.accelbyte.io # Base URL of AGS environment
AB_CLIENT_ID='xxxxxxxxxx' # Client ID from the Prerequisites section
AB_CLIENT_SECRET='xxxxxxxxxx' # Client Secret from the Prerequisites section
AB_NAMESPACE='xxxxxxxxxx' # Namespace ID from the Prerequisites section
PLUGIN_GRPC_SERVER_AUTH_ENABLED=true # Enable or disable access token validationnoteIn this app,
PLUGIN_GRPC_SERVER_AUTH_ENABLEDistrueby default. If it is set tofalse, thegRPC servercan be invoked without theAccelByte Gaming Servicesaccess token. This option is provided for development purposes only. It is recommended to enablegRPC serveraccess token validation in the production environment.
Build the Extend app
To build this app, run the following command:
make build
Test the Extend app
You can test the Extend app in a local development environment or with AGS.
Test in a local development environment
Before testing, make sure PLUGIN_GRPC_SERVER_AUTH_ENABLED is set to false. Otherwise, the gRPC request will be rejected by the gRPC server.
The custom functions in this app can be tested locally using Postman. To test the Extend app using Postman, follow these steps:
-
Run this app by using the following command:
docker compose up --build -
In Postman, create a new gRPC request, then type in
localhost:6565as the server URL. For more information, see Postman's guide about supporting gRPC. -
Continue by selecting
ProfanityFilterService/Validatemethod and invoke it with the sample payload below.{
"value": "bad"
}The response will contain
isProfane: true{
"isProfane": true,
"message": "this contains banned words"
}
Test with AGS
To test the app, which runs locally with AGS, the gRPC server needs to be connected to the internet. To do this without requiring public IP, you can use local tunnel service.
-
Run this app by using command below.
docker compose up --build -
Expose
gRPC serverTCP port 6565 in local development environment to the internet. Simplest way to do this is by using local tunnel service provider.-
Sign in to ngrok and get your
authtokenfrom the ngrok dashboard and set it up in your local environment. And, to exposegRPC serveruse following command:ngrok tcp 6565 -
Or alternatively, you can use pinggy and use only
sshcommand line to setup simple tunnel. Then to exposegRPC serveruse following command:ssh -p 443 -o StrictHostKeyChecking=no -o ServerAliveInterval=30 -R0:127.0.0.1:6565 tcp@a.pinggy.io
Please take note of the tunnel forwarding URL, e.g.,
http://0.tcp.ap.ngrok.io:xxxxxortcp://xxxxx-xxx-xxx-xxx-xxx.a.free.pinggy.link:xxxxx.infoYou may also use other local tunnel service and different method to expose the gRPC server port (TCP) to the internet.
-
-
In the Admin Portal, go to the correct namespace for this configuration and do the following:
-
On the sidebar menu, go to Game Setup > Profanity Filter > Customizations.
-
Click Add Custom Filter if you have not added any.
-
Select the option Locally hosted for testing purpose. Put the tunnel forwarding URL from the previous step and click Save.


-
-
Create an OAuth Client with
confidentialclient type and containing the following permissions:- For AGS Private Cloud customers:
ADMIN:NAMESPACE:{namespace}:PROFANITY:FILTER [UPDATE,DELETE]ADMIN:NAMESPACE:{namespace}:PROFANITY [READ]
important- Keep a copy of the
Client IDandClient Secret. - The Oauth Client created in this step is different from the one mentioned in the Prerequisites section. It is required by the Postman collection in the next step to register the
gRPC ServerURL and also to create and delete test users.
- For AGS Private Cloud customers:
-
Follow the instructions in the Postman collection (
demo/profanity-filter-demo.postman_collection.json) overview to set up the environment, using theClient IDandClient Secretfrom the previous step. Pay attention to this app console log when extend app flow is running. At least one of thegRPC Servermethods should get called when you run all the requests in the collection.
Deploy in AGS
Deploying an Extend app in AGS involves the following steps in the Admin Portal:
- Create the Extend app.
- Upload the Extend app.
- Configure the Extend app.
- Deploy the Extend app.
- Set AGS to use the Extend app.
Create the Extend app
- In the AGS Admin Portal, go to the namespace where you wish to create your Extend Override app.
- On the sidebar menu, under ADD-ONS, go to Extend > Override.
- On the Overridable Feature page, click on the + Create New button.
- On the Create App form, provide a name and description (optional) for your Extend app.
- Click Create. Your new Extend app is added to the Overridable Feature app list.
Upload the Extend app
-
Set up an IAM client for extend-helper-cli. Create an IAM client with client type
confidentialand assign the required permissions listed below. Keep a copy of theClient IDandClient Secret.- For AGS Private Cloud customers:
ADMIN:NAMESPACE:{namespace}:EXTEND:REPOCREDENTIALS[READ]ADMIN:NAMESPACE:{namespace}:EXTEND:APP[READ]
- For AGS Private Cloud customers:
-
Export the required environment variables, then build and upload the Extend app container image to AGS using extend-helper-cli.
- Ensure
<project-dir>points to your Extend app project directory - The values for
<namespace>and<app-name>can be found on theApp Detailpage of your Extend app - Use an appropriate image tag e.g.
v0.0.1
- Linux
- Windows (WSL2)
- macOS
# Your AGS environment base URL, e.g., https://spaceshooter.prod.gamingservices.accelbyte.io, https://dev.accelbyte.io, etc.
export AB_BASE_URL='https://xxxxxxxxxx'
# Client ID of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_ID='xxxxxxxxxx'
# Client Secret of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_SECRET='xxxxxxxxxx'
./extend-helper-cli-linux_amd64 image-upload --login --work-dir <project-dir> --namespace <namespace> --app <app-name> --image-tag v0.0.1# Your AGS environment base URL, e.g., https://spaceshooter.prod.gamingservices.accelbyte.io, https://dev.accelbyte.io, etc.
export AB_BASE_URL='https://xxxxxxxxxx'
# Client ID of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_ID='xxxxxxxxxx'
# Client Secret of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_SECRET='xxxxxxxxxx'
./extend-helper-cli-linux_amd64 image-upload --login --work-dir <project-dir> --namespace <namespace> --app <app-name> --image-tag v0.0.1# Your AGS environment base URL, e.g., https://spaceshooter.prod.gamingservices.accelbyte.io, https://dev.accelbyte.io, etc.
export AB_BASE_URL='https://xxxxxxxxxx'
# Client ID of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_ID='xxxxxxxxxx'
# Client Secret of OAuth Client for extend-helper-cli (from step 1)
export AB_CLIENT_SECRET='xxxxxxxxxx'
./extend-helper-cli-darwin_amd64 image-upload --login --work-dir <project-dir> --namespace <namespace> --app <app-name> --image-tag v0.0.1important- We recommend running the above commands in a separate terminal and from a different working directory than the Extend app project. This helps prevent the extend-helper-cli from inadvertently using environment variables intended for the Extend app.
- If you encounter the following error, see Troubleshooting: Docker login fails for resolution steps.
Error saving credentials: error storing credentials - err: exit status 1, out: `error storing credentials - err: exit status 1, out: `The stub received bad data.`
If your images are successfully uploaded, you will see an image with version v0.0.1 on the Image Version History page.

- Ensure
Configure the Extend app
Before deploying the Extend app that you uploaded, you must configure the environment variables required by the Extend app. In the app's details page, set the following environment variables with the same values that you used to run and test the Extend app locally.
AB_CLIENT_IDAB_CLIENT_SECRET
If your Extend Override app is based on the template before release v2024.02.13, make sure to set PLUGIN_GRPC_SERVER_AUTH_ENABLED environment variable to true. Otherwise, the access token validation in the Extend app is disabled and your Extend app may be accessed without a valid access token.
Since release v2024.02.13, PLUGIN_GRPC_SERVER_AUTH_ENABLED in Extend Override app template is set to true by default. The access token validation can only be disabled when PLUGIN_GRPC_SERVER_AUTH_ENABLED is explicitly set to false. To align with this, all new Extend apps created through the Admin Portal will not have PLUGIN_GRPC_SERVER_AUTH_ENABLED environment variable set by default. Previously, PLUGIN_GRPC_SERVER_AUTH_ENABLED=false is added on all new Extend apps created through the Admin Portal.
Deploy the Extend app
To deploy the Extend app, click Deploy Latest Image. Wait until the app status updates to RUNNING, which indicates that your Extend app is successfully deployed.
Set AGS to use the Extend app
In the Admin Portal, update the Profanity Filter customization.
Select the AccelByte hosted option and choose one of the extend app. Click Save to finish.

Next step
Proceed by modifying the Extend Override app template to implement your own custom logic. For more details, see here.