# How to get upstream and downstream dependencies?

**URL:** <https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483>\
**Category:** Install/Maintain/Configure\
**Created:** [January 4, 2023, 11:34am UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483 "2023-01-04T11:34:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![R4JxF60](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/r4jxf60/32/3334_2.png) [@R4JxF60](https://forum.gitea.com/u/R4JxF60)\
**Post date:** [January 4, 2023, 11:34am UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483/1 "2023-01-04T11:34:29Z")

</div>

I’m currently working on a feature, which uses to automate PR request testing process. I need to get the downstream and upstream dependencies from PRs before entering to the testing phase. Is there any endpoint or work around(other than the parsing HTML content of a PR) to achieve my goal?

---

<div class="post-metadata">

**Author:** ![delvh](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/delvh/32/5047_2.png) [@delvh](https://forum.gitea.com/u/delvh)\
**Post date:** [January 4, 2023, 11:48am UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483/2 "2023-01-04T11:48:20Z")

</div>

I am not quite sure I understand you correctly.  
Do you effectively want to have a CI that automatically tests your PRs?  
If that’s the case, the best course of action is probably to either set up a remote CI like Jenkins,  
or to wait for [Implement actions by wolfogre · Pull Request #21937 · go-gitea/gitea · GitHub](https://github.com/go-gitea/gitea/pull/21937) to be merged.

---

<div class="post-metadata">

**Author:** ![R4JxF60](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/r4jxf60/32/3334_2.png) [@R4JxF60](https://forum.gitea.com/u/R4JxF60)\
**Post date:** [January 5, 2023, 3:52am UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483/3 "2023-01-05T03:52:15Z")

</div>

Appreciate your quick response @delvh. Yes, I have set up a remote Jenkins instance to carry the CI. What I am asking is that following.

Let say we have two repositories in Gitea =\> repo\_1 and repo\_2

repo\_1 is the **upstream** project and repo\_2 is the **downstream** project.

Let say we have two PRs in these two repos respectively PR\_1 in repo\_1 and PR\_2 in repo\_2.

Then we add the PR\_1 as a dependency to the PR\_2. (It means that PR\_2 depends on PR\_1 and PR\_1 blocks PR\_2)

So, is there any way or a workaround to get these dependencies(with their direction) from a PR?

---

<div class="post-metadata">

**Author:** ![delvh](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/delvh/32/5047_2.png) [@delvh](https://forum.gitea.com/u/delvh)\
**Post date:** [January 5, 2023, 9:12pm UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483/4 "2023-01-05T21:12:24Z")

</div>

Ah, so you mean _those_ dependencies, not the code-related dependencies.  
I don’t think the API exposes them at the moment.  
Please open an [issue](https://github.com/go-gitea/gitea/issues/new?assignees=&labels=kind%2Ffeature%2Ckind%2Fproposal&template=feature-request.yaml) for it.

---

<div class="post-metadata">

**Author:** ![R4JxF60](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/r4jxf60/32/3334_2.png) [@R4JxF60](https://forum.gitea.com/u/R4JxF60)\
**Post date:** [January 6, 2023, 4:54am UTC](https://forum.gitea.com/t/how-to-get-upstream-and-downstream-dependencies/6483/5 "2023-01-06T04:54:06Z")

</div>

@delvh thanks for the interest, I’ll open an issue.
