# Hosting coder github detect

`POST /hosting/coder/github/detect` · Rivier · hosting

Whether Praecise Cloud can build a connected repository (a branch, a folder inside it), and as what; a stack it cannot build yet is named in a sentence.

- Scope: hosting:write
- Sdk: hosting.coderGithub.detect
- Cli: hosting coder github detect

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "repoId": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "description": "The repository's number, as the list of connected repositories gives it"
    },
    "branch": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200,
      "description": "The branch that is released; the repository's default branch when left out"
    },
    "directory": {
      "type": "string",
      "maxLength": 200,
      "description": "The folder of the project inside the repository; its root when left out"
    }
  },
  "required": [
    "repoId"
  ],
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X POST 'https://api.rivier.ai/hosting/coder/github/detect' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "repoId": 0
}'
```
