Encryption as a service using HashiCorp vault


Does anyone know how to implement the encrypt/decrypt functionality of HashiCorp Vault using its transit engine in programs? I was not able to find any code examples, only CLI and curl calls.