update api and integrat send and get method