# 제거된 API

이 페이지에서는 go-bot에 더 이상 존재하지 않는 공개 심볼, 이를 제거한 버전, 대신 사용할 것을 정리합니다.

## v0.5.0: 플랫폼 패키지를 core/ 아래로 이동

`telegram`, `discord`, `line` 패키지가 모듈 루트에서 `core/`로 이동했습니다. 아래 심볼은 새 패키지에도 같은 이름과 시그니처로 존재합니다(`SendVoice`는 예외이며 다음 섹션 참고). 바뀐 것은 import 경로뿐입니다.

| 이전 패키지(마지막 버전 v0.4.3) | 심볼 | 상태 | 대체 |
|---|---|---|---|
| `github.com/pardnchiu/go-bot/telegram` | `Bot`, `ChatStatus`, `FileType`, `Input`, `MessageOption`, `New`, `Option`, `ReplyHandler`, `SendType`, `Status`, `StatusOption`, `WithHTTPClient`, `WithPollTimeout`, `WithSendType`, `WithStatusEmoji`, `WithStatusSendType`; 메서드 `Close`, `Delete`, `FinishStatus`, `Reply`, `Save`, `Send`, `SendFile`, `SendInput`, `SendMultiSelect`, `SendPhoto`, `SendSelect`, `SendStatus`, `SendVoice`, `Start`, `Status` | Removed in v0.5.0 | `github.com/pardnchiu/go-bot/core/telegram` |
| `github.com/pardnchiu/go-bot/discord` | `Bot`, `ChannelStatus`, `Input`, `New`, `ReplyHandler`, `Status`, `StatusOption`, `WithStatusEmoji`; 메서드 `Close`, `Delete`, `FinishStatus`, `Reply`, `Save`, `Send`, `SendFiles`, `SendInput`, `SendMultiSelect`, `SendSelect`, `SendStatus`, `SendVoice`, `Start`, `Status` | Removed in v0.5.0 | `github.com/pardnchiu/go-bot/core/discord` |
| `github.com/pardnchiu/go-bot/line` | `Bot`, `Input`, `New`, `Option`, `ReplyHandler`, `Status`, `WithPath`; 메서드 `Close`, `Reply`, `Save`, `Send`, `Start`, `Status` | Removed in v0.5.0 | `github.com/pardnchiu/go-bot/core/line` |

```go
// 변경 전 (v0.4.x)
import "github.com/pardnchiu/go-bot/telegram"

// 변경 후 (v0.5.0 이상)
import "github.com/pardnchiu/go-bot/core/telegram"
```

## v0.5.0: tts 패키지와 텍스트 기반 SendVoice

| 심볼 | 상태 | 마지막 버전 | 대체 |
|---|---|---|---|
| `tts.Get(ctx, apiKey, text string) ([]byte, error)`(Gemini 음성 합성, `ffmpeg`로 OGG/OPUS 변환) | Removed in v0.5.0 | v0.4.3 | 공개 대체 없음. OGG/OPUS 파일은 자체 TTS 서비스로 생성 |
| `telegram.SendVoice(ctx, chatID, text, apiKey, caption...)` | 시그니처 변경, Removed in v0.5.0 | v0.4.3 | `core/telegram`의 `SendVoice(ctx, chatID, path, caption...)` |
| `discord.SendVoice(ctx, channelID, replyTo, text, apiKey, caption...)` | 시그니처 변경, Removed in v0.5.0 | v0.4.3 | `core/discord`의 `SendVoice(ctx, channelID, replyTo, path, caption...)` |

새 `SendVoice` 시그니처는 `caption ...string`으로 끝나므로 이전 호출도 그대로 컴파일됩니다. 텍스트는 파일 경로로 처리되고 API 키는 캡션으로 게시됩니다. 업그레이드할 때는 모든 `SendVoice` 호출을 직접 확인하세요.

## 관련 페이지

- [Telegram 메시지](/ko/telegram-messages), [Discord 메시지](/ko/discord-messages)
- [v0.5.0 릴리스 노트](/released/v0.5.0)
