mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 02:09:37 +02:00
Add ability to list imports of a channel sync
This commit is contained in:
parent
0567049a98
commit
a3b472a12e
37 changed files with 565 additions and 179 deletions
|
@ -6,7 +6,8 @@ import {
|
|||
VideoChannel,
|
||||
VideoChannelCreate,
|
||||
VideoChannelCreateResult,
|
||||
VideoChannelUpdate
|
||||
VideoChannelUpdate,
|
||||
VideosImportInChannelCreate
|
||||
} from '@shared/models'
|
||||
import { unwrapBody } from '../requests'
|
||||
import { AbstractCommand, OverrideCommandOptions } from '../shared'
|
||||
|
@ -182,11 +183,10 @@ export class ChannelsCommand extends AbstractCommand {
|
|||
})
|
||||
}
|
||||
|
||||
importVideos (options: OverrideCommandOptions & {
|
||||
importVideos (options: OverrideCommandOptions & VideosImportInChannelCreate & {
|
||||
channelName: string
|
||||
externalChannelUrl: string
|
||||
}) {
|
||||
const { channelName, externalChannelUrl } = options
|
||||
const { channelName, externalChannelUrl, videoChannelSyncId } = options
|
||||
|
||||
const path = `/api/v1/video-channels/${channelName}/import-videos`
|
||||
|
||||
|
@ -194,7 +194,7 @@ export class ChannelsCommand extends AbstractCommand {
|
|||
...options,
|
||||
|
||||
path,
|
||||
fields: { externalChannelUrl },
|
||||
fields: { externalChannelUrl, videoChannelSyncId },
|
||||
implicitToken: true,
|
||||
defaultExpectedStatus: HttpStatusCode.NO_CONTENT_204
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue