Soomda 서비스를 위한 통합 API 엔드포인트
/api/v1/emotion-tags/{language}.json
언어별 감정 태그 데이터 (en, ko 등)
/api/v1/breathing-patterns/{language}.json
언어별 호흡 패턴 데이터 (en, ko 등)
// 감정 태그 가져오기
const emotionTags = await fetch('https://soomda.com/api/v1/emotion-tags/ko.json')
const tags = await emotionTags.json()
// 호흡 패턴 가져오기
const breathingPatterns = await fetch('https://soomda.com/api/v1/breathing-patterns/ko.json')
const patterns = await breathingPatterns.json()
// 감정 태그 가져오기
let url = URL(string: "https://soomda.com/api/v1/emotion-tags/ko.json")!
let (data, _) = try await URLSession.shared.data(from: url)
let emotionTags = try JSONDecoder().decode(EmotionTagData.self, from: data)
// 호흡 패턴 가져오기
let breathingURL = URL(string: "https://soomda.com/api/v1/breathing-patterns/ko.json")!
let (breathingData, _) = try await URLSession.shared.data(from: breathingURL)
let patterns = try JSONDecoder().decode(BreathingPatternData.self, from: breathingData)
# 감정 태그 조회
curl https://soomda.com/api/v1/emotion-tags/ko.json
# 호흡 패턴 조회
curl https://soomda.com/api/v1/breathing-patterns/en.json
# 버전 정보 조회
curl https://soomda.com/api/v1/version.json