Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Endpoint to create DataSource

未关闭
#44 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
45/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
冷清
领域
api, backend, database

调研方向

首先定位 POST /api/v1/advocacy_groups/:id/data_sources/ 的路由,以及 datasets.data_sources 和 advocacy_group_data_sources 的模型或迁移。检查现有的 endpoint 测试和身份验证模式;完成的标准是验证两个记录的创建、适当的授权、一致的错误处理以及已更新的 API 文档。

由索引模型根据 Issue 内容生成。

描述

Advanced California Tribal GIS Hackathon

🛠️ Create DataSource


📋 Endpoints Required

  • POST /api/v1/advocacy_groups/:id/data_sources/ — create resource

🗂️ Data Schema

Describe or paste the expected request/response shape below.

{
  name: string,
  description: string,
  url: string <optional>,
  tags: string[],
  allowAggregation: boolean
}

✅ Acceptance Criteria

  • All endpoints return correct HTTP status codes
  • Input validation is applied to request bodies and query params
  • Errors return consistent, descriptive JSON responses
  • Endpoints are protected by appropriate auth/authorization middleware
  • Pagination supported on the list endpoint
  • Unit tests cover each endpoint (happy path + error cases)
  • Integration tests pass in CI
  • OpenAPI / Swagger docs updated

🔒 Auth & Permissions

N/A

🔗 Related


💬 Additional Context

This Endpoint will require writing data into two tables: datasets.data_sources and advocacy_group_data_sources. The constructor for the latter junction table will be like this:

{
  advocacy_group_id: number,
  data_source_id: number
}
主要语言
HTML
星标
2
派生
11
PR 合并指标
30 天内没有已合并 PR

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

OpenSourceFellows/map_dashboard_hackathon 的其他 Issue

查看 OpenSourceFellows/map_dashboard_hackathon 的全部 Issue

相似的 Issue

更多 Backend & API Design Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。