API support for creation of credits?

Created on 30 July 2025, 16 days ago

This is more of a question, though I'm happy to turn it into a formal feature request. Do you expect to have any sort of write API support for recognizing contributions? I understand there's potential for abuse at a larger scale, but I'm just thinking 1) having a separate interface now for everything increases the likelihood that code credits won't be logged (when they could be tooled to do so) and 2) an API could actually be expanded to support things like credits for projects maintained in other repositories (though maybe that's undesirable).

For the near term, I'm just concerned by the blog post recently published that seems to indicate in the future we'll be maintaining issues on GitLab but expected to come to a separate interface after the fact to credit contributions on d.o. 🧐

But also I might be misreading it or not understanding the roadmap. πŸ˜…

✨ Feature request
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States rszrama

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @rszrama
  • πŸ‡ͺπŸ‡ΈSpain fjgarlin

    You are not misreading, but it's a yes and no. Everything will be cross linked, but there will be a separate place to assign the credits. GitLab cannot attribute organizations.

    We have designed the system so we can have multiple sources of credits, like GitLab issues, or d.o issues, but yeah, it all comes together via the new UI.

    Everything is crosslinked and you should be able to do the same attribution as you can now. I understand that going out of the issue page might not be ideal, but it's only one extra click. In fact, for the majority of users, once you save your defaults, you won't need to go to the new system as it is designed to automatically pull the information from the issue. If you make a comment in the issue, you will be added to the contribution record.

    In terms of API, we are not considering creating one to add/edit credits, although it is possible (this is exactly how credits were transferred from D7 to the new site. See this: https://git.drupalcode.org/project/contribution_records/-/blob/1.0.x/con...)

    We are also considering the possibility of communicating to the new system from GitLab issues, as we have webhooks in place (see some pseudocode here https://git.drupalcode.org/project/drupalorg/-/blob/1.0.x/src/Plugin/Que...).

    In terms of milestones, first it's the new contribution system (aka this), then GitLab issues, and then we'd be able to focus on improvements and new features. But again, the new system pulls the information automatically.

    I will mark this as "won't fix" as it's not on our roadmap to create an API for external use to add/edit credits.

  • πŸ‡ΊπŸ‡ΈUnited States rszrama

    Thanks for the info! And makes sense re: auto attribution. So basically as a maintainer, once I close an issue, I just need to ensure that I go and create the record? Or will it be automatically creating the records, too, based on each active user's contribution settings?

    (I guess it needs human review to ensure that people who just commented without contributing are removed?)

  • πŸ‡ͺπŸ‡ΈSpain fjgarlin

    The record is created automatically, so no need to do that. As a maintainer, you'd only need to go to the record page and tick the checkboxes of the contributors that you want to give credit to.

    Each contributor can change attribution as needed, but you, as maintainer, only need to worry about the checkboxes.

    For example, I just went to: https://new.drupal.org/contribution-record?source_link=https://www.drupa...
    And I could already see your attribution to "Centarro". All I'd need to do is check the credit box and save.

  • πŸ‡ΊπŸ‡ΈUnited States rszrama

    Got it! Thanks for the explanation. 😊

Production build 0.71.5 2024